Skip to content

Instantly share code, notes, and snippets.

@francisbyrne
francisbyrne / chmodr.sh
Created September 16, 2012 07:54
Recursive chmod script for dirs and/or files
#!/bin/sh
#
# chmodr.sh
#
# author: Francis Byrne
# date: 2011/02/12
#
# Generic Script for recursively setting permissions for directories and files
# to defined or default permissions using chmod.
#
@rxaviers
rxaviers / gist:7360908
Last active November 19, 2024 06:37
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
@reorx
reorx / networkservice.sh
Created June 27, 2017 06:50
macOS: get current active network device name, interface, mac
#!/bin/bash
services=$(networksetup -listnetworkserviceorder | grep 'Hardware Port')
while read line; do
sname=$(echo $line | awk -F "(, )|(: )|[)]" '{print $2}')
sdev=$(echo $line | awk -F "(, )|(: )|[)]" '{print $4}')
#echo "Current service: $sname, $sdev, $currentservice"
if [ -n "$sdev" ]; then
ifout="$(ifconfig $sdev 2>/dev/null)"
@nstanke
nstanke / enable_ws.sh
Last active March 5, 2024 14:43
Synology Bitwarden_rs Websocket setup without SSH
#!/bin/bash
LOC_DIR="/etc/nginx"
if [ ! -f $LOC_DIR/ws.locations ]; then
echo """
location /notifications/hub {
proxy_pass http://localhost:$3;
proxy_set_header Upgrade \$http_upgrade;
proxy_set_header Connection "upgrade";
@MilesTEG1
MilesTEG1 / volume_sur_ssd_mvne_dans_NAS_Synology.md
Last active June 18, 2024 03:12
Utiliser un SSD MVNe dans un NAS Synology en tant que volume et pas en tant que cache

Utiliser un SSD MVNe dans un NAS Synology en tant que volume et pas en tant que cache

Objectif final :
Déplacer le dossier docker, et le paquet Docker sur le volume SSD NVMe pour gagner en fluidité. Voir §-III. à la fin de ce GIST.

Note :
Les commandes suivantes sont pour la plupart à lancer en root dans un terminal, pensez à faire un : sudo -i