to make easy, and not remeber all of this typo mistake bin folder on my home foler
Last active
March 25, 2018 07:56
-
-
Save azizzaeny/810a75263f00eee69dcbfd17ab2e9f17 to your computer and use it in GitHub Desktop.
all my bin files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
oc | |
boot | |
lein | |
.#* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# asume use is io | |
sudo chown -R io:io /home/io/.emacs.d/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo chown io:io /media/io/ | |
sudo chown io:io /media/io/flash/ | |
sudo chown io:io /media/io/EFI/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo swapoff /mnt/host/swapfile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Selected options for "emacsclient" | |
# | |
# -c Create a new frame instead of trying to use the current | |
# Emacs frame. | |
# | |
# -e Evaluate the FILE arguments as ELisp expressions. | |
# | |
# -n Don't wait for the server to return. | |
# | |
# -t Open a new Emacs frame on the current terminal. | |
# | |
# Note that the "-t" and "-n" options are contradictory: "-t" says to | |
# take control of the current text terminal to create a new client frame, | |
# while "-n" says not to take control of the text terminal. If you | |
# supply both options, Emacs visits the specified files(s) in an existing | |
# frame rather than a new client frame, negating the effect of "-t". | |
# check whether an Emacs server is already running | |
pgrep -l "^emacs$" > /dev/null | |
# otherwise, start Emacs server daemon | |
if [ $? -ne 0 ]; then | |
emacs --daemon | |
fi | |
# return a list of all frames on $DISPLAY | |
emacsclient -e "(frames-on-display-list \"$DISPLAY\")" &>/dev/null | |
# open frames detected, so open files in current frame | |
if [ $? -eq 0 ]; then | |
emacsclient -n -t "$@" | |
# no open frames detected, so open new frame | |
else | |
emacsclient -n -c "$@" | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# this asume swapfile mounted host | |
sudo chmod 0600 /mnt/host/swapfile | |
sudo mkswap /mnt/host/swapfile | |
sudo swapon /mnt/host/swapfile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# asume mnt/host already mounted | |
# and file are /mnt/host/persist-chrome and /mnt/host/persist-down | |
sudo /home/io/bin/umount-downloads | |
sudo /home/io/bin/umount-chrome | |
sudo fsck -l /mnt/host/persist-chrome | |
sudo fsck -l /mnt/host/persist-down |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# git add all commit message arguments into origin master branch | |
git add . | |
git commit -m "$*" | |
git push origin master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo mksquashfs overlay filesystem.squashfs.xz -info -progress -comp xz -b 1048576 -Xdict-size 100% | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# asume host already mounted on /mnt/host | |
# which name of file persist-down | |
sudo mount -t ext4 -o rw,loop /mnt/host/persist-down /home/io/Downloads/ | |
sudo chown io:io /home/io/Downloads/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# mount /mnt/host/img/home.sqsh /mnt/home | |
echo "this feature disabled for a a while because home would divided" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# mounting host depends on drive usualy /dev/sda1 but in this case we get /dev/sda3 | |
sudo mkdir -p /mnt/host | |
sudo mount -t ntfs -o rw $1 /mnt/host | |
# check arguments should like that |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# asume host already mounted on /mnt/host | |
# which name file persist-chrome | |
# asume name media flash | |
sudo /home/io/bin/chown-flash | |
sudo mkdir -p /mnt/{overlay-chrome,overlay-chrome-ro} | |
sudo mount -o ro -t squashfs /media/io/flash/google.sqsh /mnt/overlay-chrome-ro/ | |
# sudo mount -o rw,loop -t ext4 /mnt/host/persist-chrome /mnt/overlay-chrome/ | |
sudo mount -t tmpfs none /mnt/overlay-chrome/ | |
sudo mkdir -p /mnt/overlay-chrome/{rw,work} | |
sudo mount -t overlay -o lowerdir=/mnt/overlay-chrome-ro/,upperdir=/mnt/overlay-chrome/rw/,workdir=/mnt/overlay-chrome/work/ overlay /home/io/.config/google-chrome/ | |
sudo chown io:io /home/io/.config/google-chrome/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo mkdir -p /mnt/{overlay,lower,rw} | |
sudo mount -t squashfs -o ro,loop filesystem.squashfs /mnt/lower | |
sudo mount -t tmpfs none /mnt/rw | |
sudo mkdir -p /mnt/rw/{work,upper} | |
sudo mount -t overlay -o lowerdir=/mnt/lower,upperdir=/mnt/rw/upper,workdir=/mnt/rw/work overlay /mnt/overlay |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sync | |
/home/io/bin/umount-host | |
echo "choose host on $1" | |
/home/io/bin/mount-host $1 | |
/home/io/bin/mount-downloads | |
/home/io/bin/overlay-chrome | |
/home/io/bin/enable-swap | |
sudo df -ah | |
sudo free -h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sync | |
/home/io/bin/umount-downloads | |
/home/io/bin/umount-chrome | |
/home/io/bin/disable-swap | |
/home/io/bin/umount-host | |
sudo df -ah |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
boot -C cider repl -s wait |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo umount /home/io/.config/google-chrome/ | |
sudo umount /mnt/overlay-chrome/ | |
sudo umount /mnt/overlay-chrome-ro/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# asume downloads already mounted on host | |
sudo umount /home/io/Downloads/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo umount /mnt/host |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "/lib/live/mount/persistence/" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# required arguments $! uuid | |
nmcli c up uuid $1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
nmcli c down uuid b45e370d-310f-4a85-8cb6-dfa20eb3c828 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
nmcli c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
nmcli c up uuid b45e370d-310f-4a85-8cb6-dfa20eb3c828 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment