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 | |
set -x | |
# By Nick Semenkovich https://nick.semenkovich.com | |
# | |
# Largely derived from: | |
# https://gist.github.com/kumbasar/49906cb704ce9213c972a3e008c74c0c | |
# I found myself needing to update an Xbox S via USB (with the Offline System Update OSU1 patch) | |
# See: https://support.xbox.com/en-US/help/hardware-network/console/system-update-solution/offline-system-update |
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 | |
# set -x | |
# Inspired by https://kb.10xgenomics.com/hc/en-us/articles/360023793031-How-can-I-convert-the-feature-barcode-matrix-from-Cell-Ranger-3-to-a-CSV-file- | |
FILES="GSM*_barcodes.tsv" | |
for i in $FILES | |
do | |
filename="${i%_*}" # Extract prefix before _barcodes.txv |
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 | |
if [ ! $(pidof tcpdump) ]; then | |
echo "Starting tcpdump" | |
/usr/sbin/tcpdump -i eth0 -n -W 1000 -G 3600 -z gzip -w /var/www/traffic-logs/%m-%d-%y-%H:00.pcap >/dev/null 2>&1 & | |
else | |
echo "already running" | |
fi | |
# That 1000 doesn't really work. Maybe gzip bug. |
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 | |
export PATH="/usr/lib/ccache:$PATH" | |
die() { echo "$@" 1>&2 ; exit 1; } | |
if [ -z $1 ]; then | |
die "Run with a git tag, e.g.: $0 v4-2-test" | |
fi | |
echo "Updating samba4 to tag '$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
# Work in progress! | |
# Derived from http://stackoverflow.com/questions/25709398/set-location-of-special-folders-with-powershell | |
<# | |
.SYNOPSIS | |
Sets a known folder's path using SHSetKnownFolderPath. | |
.PARAMETER Folder | |
The known folder whose path to set. | |
.PARAMETER Path | |
The path. |
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
Here is the list of largely undocumented Office 365 MDM PowerShell commands: | |
CommandType Name Version Source | |
----------- ---- ------- ------ | |
Function Add-ComplianceCaseMember 1.0 tmp_00mf4ap5.eg0 | |
Function Add-eDiscoveryCaseAdmin 1.0 tmp_00mf4ap5.eg0 | |
Function Add-RoleGroupMember 1.0 tmp_00mf4ap5.eg0 | |
Function Get-ActivityAlert 1.0 tmp_00mf4ap5.eg0 | |
Function Get-AdminAuditLogConfig 1.0 tmp_00mf4ap5.eg |
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
Onhub urls: | |
onhub.here internally resolves to the router (always 192.168.86.1) | |
http://onhub.here/api/v1/status | |
http://onhub.here/api/v1/welcome-mat | |
http://onhub.here/api/v1/connected-devices | |
http://onhub.here/api/v1/diagnostic-report <-- protobuf with gzipped chunks |
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
### Keybase proof | |
I hereby claim: | |
* I am semenko on github. | |
* I am semenko (https://keybase.io/semenko) on keybase. | |
* I have a public key whose fingerprint is FF4D D3EC 3ADD 5006 6246 1007 06F5 B6F6 DBBB 3C45 | |
To claim this, I am signing this object: |
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/sh | |
# Author: Nick Semenkovich <[email protected]> | |
git remote update >/dev/null 2>&1 | |
gitstatus=`git log master..origin/master` | |
if [ "$gitstatus" ] | |
then | |
if tty -s |
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/sh | |
# Get called script name (e.g. myscript.sh) | |
SCRIPTNAME=$(basename $0) | |
if tty -s | |
then | |
USER_TTY=`tty` | |
# Be annoying. | |
echo "\a@@@ WARNING @@@:\nThe $SCRIPTNAME tool has been discontinued by the NCBI." > $USER_TTY | |
echo "Please consider converting your scripts to use the new BLAST+ tools.\n" > $USER_TTY | |
# Hide errors if they pass something incorrect to the tool. |
NewerOlder