Skip to content

Instantly share code, notes, and snippets.

View Oceanswave's full-sized avatar
🎯
Focusing

Sean McLellan Oceanswave

🎯
Focusing
View GitHub Profile
@Oceanswave
Oceanswave / gist:0f157e66df1d090411ae
Last active March 1, 2018 09:00
Install Barista on SP2013

Screencast of a Barista deployment on SP2013

This gist shows how a normal Barista installation from scratch goes on SP2013.

There's some sort of impression that there's some magic going on here. There's not. A single command gets run with at max 4 parameters.

Screencapture GIF

note the time in the lower right corner. Takes 2 minutes 32 seconds overall on not-a-super-computer single VM SP2013 installation with typing included.

@Oceanswave
Oceanswave / gist:fbbb838861a017bf869d
Created June 16, 2015 02:53
FFMPEG GoPro Timelapse
ffmpeg -f image2 -start_number 22096 -i G01%05d.JPG -vcodec libx264 -b:v max -s 1920x1080 stx.mp4
@Oceanswave
Oceanswave / gist:9ff4b05bfd8c5c9d42a1
Created June 17, 2015 03:17
More FFMPEG timelapse fun
ls -1v | grep JPG > files.txt
mencoder -nosound -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=21600000 -o windowsill_flowers_7.avi -mf type=jpeg:fps=24 mf://@files.txt -vf scale=1920:1080
4k@90fps, no sound
ls -1v | grep JPG > files.txt
mencoder -nosound -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=21600000 -o windowsill_flowers_7.avi -mf type=jpeg:fps=90 mf://@files.txt -vf scale=3840:2160
mylist.txt:
file stx-am-2.mp4
file stx-pm-2.mp4
ffmpeg -f concat -i mylist.txt -c copy output.mpg
@Oceanswave
Oceanswave / gist:eb310e022cea56ccfe95
Last active March 1, 2018 08:56
Extract data from pfx for AWS Api Gateway
Get OpenSSL:
https://www.openssl.org/related/binaries.html
Procedure
create an CSR, submit it to a CA, Get the CER back, Import into MMC -> Certificates Snapin, Export with private key.
Take the file you exported (e.g. certname.pfx) and copy it to a system where you have OpenSSL installed. Note: the *.pfx file is in PKCS#12 format and includes both the certificate and the private key.
Certificate Body:
Run the following command to export the certificate: openssl pkcs12 -in certname.pfx -nokeys -clcerts -out name.pem
@Oceanswave
Oceanswave / addLocalUser.ps1
Last active March 1, 2018 08:58
Powershell function to add a user to a local group
function Add-LocalUser{
Param(
$computer=$env:computername,
$group='Guests',
$userdomain=$env:userdomain,
$username=$env:username
)
([ADSI]"WinNT://$computer/$Group,group").psbase.Invoke("Add",([ADSI]"WinNT://$domain/$user").path)
}
Since you're getting old and senile.
1) Run node script to output files in date order to a file.
var recursive = require('recursive-readdir');
var fs = require("fs");
var inputFolder = process.argv[2];
if (!inputFolder) {
console.log("** YOU GOTTA SPECIFY THE TARGET PATH AS THE FIRST PARAM! **");
@Oceanswave
Oceanswave / gist:0ba18f598e5482f0572d663699cbf4a1
Last active July 19, 2022 06:05
Tips on configuring OpenWRT chaos_calmer on MR3040 v2 to use extoverlay

The issue is that chaos_calmer default image doesn't have enough storage to hold kmod-fs-ext4 on the MR3040. ug!

This is a good start, https://wiki.openwrt.org/doc/howto/extroot

but there's some other tips here.

So, you've got to use image generator to make a custom image that initially doesn't have luci initially, but does have kmod-fs-ext4.

This is much simpler if you've already configured the router and it's connected to the internet.

@Oceanswave
Oceanswave / TODO
Last active March 1, 2018 08:57
TODO - Stuff that I need to work on
Things to do...
@Oceanswave
Oceanswave / SharePoint Online Custom New Doc Set
Last active November 30, 2020 10:00
A custom New Document Set page (newdocset.aspx) in SharePoint Online
.