This file contains hidden or 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 | |
container_ids=$(docker ps -q) | |
for container_id in $container_ids; do | |
sudo truncate -s 0 $(docker inspect --format='{{.LogPath}}' "$container_id") | |
done |
This file contains hidden or 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
# enable autofocus of webcam | |
sudo v4l2-ctl -d 1 -c focus_automatic_continuous=1 | |
# fix save dialog freezing brave | |
# https://community.brave.com/t/brave-browser-freezes-on-uploading-or-downloading-any-file-in-ubuntu/453578/10 | |
dconf write /org/gnome/desktop/sound/input-feedback-sounds false |
This file contains hidden or 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
<touchégg> | |
<settings> | |
<property name="animation_delay">150</property> | |
<property name="action_execute_threshold">20</property> | |
<property name="color">auto</property> | |
<property name="borderColor">auto</property> | |
</settings> | |
<application name="All"> |
This file contains hidden or 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 | |
printUsage() { | |
cat <<EOM | |
Usage: cm [OPTION]... [MESSAGE] | |
Options: | |
--scope,-s Scope of the change. | |
Commit Types | |
--bulid Changes related to configs, dependencies etc. |
This file contains hidden or 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
#redirect all request to port 80 to 443 ( http -> https ) | |
server { | |
listen 80; | |
server_name servername; | |
return 301 https://$host$request_uri; | |
} | |
server { | |
listen 443 ssl; |
This file contains hidden or 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
git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/[ \1 ] /' | |
} | |
PS1="\[\033[02;37m\]\$(git_branch)\[\033[00m\]\[\033[01;32m\]\u\[\033[00m\]:\[\033[01;34m\]\W \[\033[00m\]\$ " | |
# Git commit using emoji | |
cm() { | |
# Menu |