See how a minor change to your commit message style can make a difference.
Tip
Have a look at git-conventional-commits , a CLI util to ensure these conventions, determine version and generate changelogs
| #!/bin/bash | |
| # Kill the top disk-writing process when a filesystem exceeds a usage threshold. | |
| # Usage: disk-guardian [threshold%] [mountpoint] | |
| # /tmp/disk-guardian | |
| THRESHOLD="${1:-95}" | |
| MOUNTPOINT="${2:-/}" | |
| LOG="/var/log/disk-guardian.log" |
| #!/bin/bash | |
| # VPN connect script - fixes stale connections after WiFi change | |
| # Usage: ./vpn.sh | |
| # Please change OVPN_CONFIG and VPN_PASS | |
| OVPN_CONFIG="./client.ovpn" | |
| OVPN_DIR="$(dirname "$OVPN_CONFIG")" | |
| VPN_PASS="YOUR_VPN_PASSWORD_HERE" | |
| # --- Require sudo upfront and keep it alive --- |
See how a minor change to your commit message style can make a difference.
Tip
Have a look at git-conventional-commits , a CLI util to ensure these conventions, determine version and generate changelogs
| import numpy as np | |
| import pandas as pd | |
| import torch | |
| from sklearn.metrics import ( | |
| accuracy_score, | |
| balanced_accuracy_score, | |
| f1_score, | |
| roc_auc_score, | |
| ) |
| #!/usr/bin/env python3 | |
| import os | |
| import argparse | |
| import glob | |
| from pydub import AudioSegment | |
| def stereo2mono(files): | |
| """Convert all files from stereo to mono. | |
| Note: this would effectively also create a copy of files that were already in a mono format | |
| Parameters |
| import os | |
| import pathlib | |
| import matplotlib.pyplot as plt | |
| import numpy as np | |
| import seaborn as sns | |
| import tensorflow as tf | |
| from tensorflow.keras.layers.experimental import preprocessing | |
| from tensorflow.keras import layers |
| #!/usr/share/env python3 | |
| # demo zeropadding | |
| # dimodifikasi dari: https://dsp.stackexchange.com/questions/10363/algorithm-to-zero-pad-data-before-fft | |
| # ada implementasi yang lebih mudah dari ini yakni dengan menggunakan np.pad | |
| import numpy as np | |
| import matplotlib.pyplot as plt | |
| from scipy.fftpack import fft, fftshift | |
| Fs = 16000 # Frekuensi sampling | |
| f0 = 5000 # Frekuensi tengah |
| # vimcheat.sh: the vim cheatsheet | |
| # Ref: https://www.catswhocode.com/blog/vim-cheat-sheet-for-2016 | |
| # Usage: less `vimcheat.sh` then `/typewhatyoulookfor` | |
| # :command arguments Explanation for command inside VIM OR | |
| # shortcut Explanation for shortcut, eg: ciw (C+I+W) to change inner word | |
| #Basics | |
| :e filename Open filename for edition | |
| :w Save file | |
| :q Exit Vim |