From https://thomasleplus.github.io/bookmarklets/
If you don’t know what bookmarklets are, I recommend this introduction.
If you are familiar with bookmarklets but you are not sure how to install one, you can find detailed instructions here.
#!/usr/bin/env zsh | |
# Setup script for a new macOS machine | |
# Version of Ruby to use with `chruby` | |
rubyver="3.2.2" | |
# Bold font | |
bold=$(tput bold) | |
normal=$(tput sgr0) |
From https://thomasleplus.github.io/bookmarklets/
If you don’t know what bookmarklets are, I recommend this introduction.
If you are familiar with bookmarklets but you are not sure how to install one, you can find detailed instructions here.
# Henry Bley-Vroman, 2019 | |
# | |
# Usage | |
# Paste or source this into your shell profile. | |
# Requires macOS and that your shell supports [[ ]] and '<string> == <starting substring>*' | |
# (Bash, Zsh, Ksh etc) | |
# alias php to the latest PHP installed with MAMP | |
MAMP_PHP__LATEST=$(ls /Applications/MAMP/bin/php/ | sort -V | tail -1) | |
alias php="/Applications/MAMP/bin/php/${MAMP_PHP__LATEST}/bin/php -c \"/Library/Application Support/appsolute/MAMP PRO/conf/${MAMP_PHP__LATEST}.ini\"" |
This is based on a guide on the Ubnt forums.
Log into your Edgerouter and run the following - sudo -i && vi /config/user-data/update-adblock-dnsmasq.sh
This will switch you to the root user and open up vi
.
#!/bin/bash
I hereby claim:
To claim this, I am signing this object:
Sub AddProgressBar() | |
' Parameters to set | |
progressBarHeight = 3.5 ' height of the progress bar | |
FillColor = RGB(251, 0, 6) ' Fill color of the progress bar | |
LineColor = FillColor ' Line color of the progress bar | |
BackgroundColor = RGB(255, 255, 255) ' background color of the progress bar | |
fontColor = FillColor | |
startingSlideNo = 1 | |
noFontSize = 13 | |
showSlideNo = True |
cd repository | |
git checkout --orphan orphan_name | |
git rm -rf . | |
rm '.gitignore' | |
echo "#Title of Readme" > README.md | |
git add README.md | |
git commit -a -m "Initial Commit" | |
git push origin orphan_name |
Wiring up a Google Form to GitHub is not that difficult with a little bit of Apps Script automation. All you need is a Google account, a GitHub account, and a web browser...
Personal access tokens provide an easy way to interact with the GitHub API without having to mess with OAuth. If you don't already have a personal access token with repo or public_repo access, visit your GitHub settings page and generate a new token.
Be sure to copy your token some place safe and keep it secure. Once generated, you will not be able to view or copy the token again.
// _decimal.scss | MIT License | gist.github.com/terkel/4373420 | |
// Round a number to specified digits. | |
// | |
// @param {Number} $number A number to round | |
// @param {Number} [$digits:0] Digits to output | |
// @param {String} [$mode:round] (round|ceil|floor) How to round a number | |
// @return {Number} A rounded number | |
// @example | |
// decimal-round(0.333) => 0 |
##Create an alias to MAMP's PHP installation
To do this, we can simply create an alias for our bash profile. We'll be doing this is nano, though you can do it in vim or a number of other editors as well.
Within the terminal, run:
nano ~/.bash_profile
This will open nano with the contents, at the top in a blank line add the following line: