Tumgik
0x1b · 8 years
Link
Yosemite logical volumes cannot be read on Windows bootcamp anymore since they are not HFS+ volumes but they are now CoreStorage.
0 notes
0x1b · 8 years
Text
Remove unnecessary Windows 10 entries from rEFInd
rEFInd detects unnecessary entries for Windows 10. This is how I removed them.
rEFInd is now installed under the ESP volume if you choose default installation on OS X 10.10 Yosemite or later. So, mount it first, then edit the conf file next.
mkdir /Volumes/esp sudo mount -t msdos /dev/disk0s1 /Volumes/esp vim /Volumes/esp/EFI/refind/refind.conf
refind.conf should have the commented line like #dont_scan_volumes "Recovery HD", so add an line the below:
#dont_scan_volumes "Recovery HD" dont_scan_volumes "BOOTCAMP","NTFS volume"
Then restart the Mac, you won't see the entries anymore.
1 note · View note
0x1b · 8 years
Text
(Re)start specific background command
Useful when (re)start specific background command:
PID=$(ps aux | grep '<command>' | awk '{ print $2 }') [ -z "${PID}" ] && kill ${PID} nohup <command> 2>&1 | logger & unset PID
0 notes
0x1b · 8 years
Text
One time job with at despite cron repeats
at is a command to execute one time job despite cron repeats the job.
at 3:30 AM << __JOBS__ whoami > ./whoami.txt __JOBS__
The example above will create whoami.txt in the current directory and put the result of whoami command at 15:30.
atq to check left jobs
atrm to delete a left job
0 notes
0x1b · 8 years
Text
Generate pronounceable password
Generate it with pwgen:
pwgen -01A
0 notes
0x1b · 8 years
Text
Remove conflicted copies of Dropbox
find | grep | xargs rm doesn't cope with file names having spaces, so I choose -name instead.
find . -type f -name '*conflicted copy *' -print0 | xargs -0 rm
1 note · View note
0x1b · 8 years
Link
TotalTerminal dies sadly. iTerm2 has Quake-style visor just like TotalTerminal. This will be my alternative choice.
0 notes
0x1b · 8 years
Link
0 notes
0x1b · 8 years
Link
Webhook service for cross-brower JavaScript testing CI. This seems dead though.
0 notes
0x1b · 8 years
Link
List of icense identifiers
0 notes
0x1b · 8 years
Text
Check log from Android Browser
Connect adb and;
adb logcat browser:V *:S
0 notes
0x1b · 10 years
Text
Sort single line with space delimiter
xargs seems awesome:
echo 'B A C' | xargs -n 1 | sort | xargs
0 notes
0x1b · 10 years
Text
Crop multiple image files at once with GraphicsMagick
Crop multiple images:
gm mogrify -output-directory ./OUTPUT_PATH -crop WxH+X+Y *.EXT
1 note · View note
0x1b · 10 years
Text
Clear DNS cache on Mac OS X
Run the command below:
sudo killall -HUP mDNSResponder
0 notes
0x1b · 11 years
Text
Note about CFLAGS & LDFLAGS
This may be helpful when you get errors during compiling source codes.
CFLAGS as environment variable sets PATH to include directory
LDFLAGS as environment variable sets PATH to lib directory
For example, adding another openssl from Homebrew to compile something:
CFLAGS="-I$(brew --prefix openssl)/include" LDFLAGS="-L$(brew --prefix openssl)/lib" make
This make you use specified openssl to make
0 notes
0x1b · 11 years
Text
Git: Ignoring specific file from staging
Sometimes I want change some files that I don't want to stage the changes. For example, developing a web app on `localhost` and changing the configuration file temporary should be happens. Now Git supports this use case. If you want to ignore specific file from staging: git update-index --assume-unchanged And when you want to track changes again: git update-index --no-assume-unchanged This is useful when you want to stage everything by `git add -A` or something :D
1 note · View note
0x1b · 11 years
Text
Concatenate multiple PDFs into a single PDF
Ghostscript will help you:
gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=merged.pdf source1.pdf source2.pdf source3.pdf etc.pdf
2 notes · View notes