#Jenkins Query Params
JenkinsBaseURL: "https://jenkins.yourco.com"
JenkinsJobName: "<YOUR JOB NAME>"
JenkinsMultibranchPipelineBranchName: "master"
JenkinsBuildQuery: "(builds[?artifacts[?contains(fileName, '{{ArtifactDesiredVersion}}') == `true`]])[0]" # Partial artifact file name - this assumes your file names are unique per build
JenkinsBuild: "{{ (jenkins.content | from_json) | json_query(JenkinsBuildQuery) }}"
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
# This basically creates a fork-bomb where each forked process is splitting out one top-level folder | |
$MaxSimultaneousJobs = $(Get-WmiObject –class Win32_processor).NumberOfCores * .5 | |
Write-Host "Processing up to $MaxSimultaneousJobs at a time" | |
Get-ChildItem -Directory | Foreach-Object { | |
$FolderName = """$($_.Name)""" | |
$BranchName = $_.Name -Replace(' ','-') | |
while (@(Get-Job -State Running).Count -ge $MaxSimultaneousJobs) { |
I hereby claim:
- I am crossan007 on github.
- I am crossan007 (https://keybase.io/crossan007) on keybase.
- I have a public key ASBeYWUz3Uibu1jTf8gsXZzmm9rPqCUGaf2qhLnVh2cougo
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
$VMName = "MyCoolVM" | |
$NewDiskSize = 102400 | |
$VBoxManage = 'C:\Program Files\Oracle\VirtualBox\VBoxManage.exe' | |
# Gather data from VBoxManage | |
$VBOXDrive = & $VBoxManage showvminfo $VMName | Select-String ".vmdk" | |
$RegEx = 'SATA \((\d),\s?(\d)\):\s?(.*?)\s\(UUID:(.*?)\)' | |
$M = [System.Text.RegularExpressions.Regex]::Matches($VBOXDrive,$RegEx) | |
$VMDK = $M.Groups[3].Value |
[[TOC]]
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
Function Set-GifSpeed { | |
Param( | |
$inputFile, | |
$SpeedFactor | |
) | |
$Name = $(Split-Path $inputFile -Leaf) | |
$outPath = $(Split-Path $inputFile -Parent)+"\out" | |
New-Item -Path $outPath -ItemType Directory -ErrorAction SilentlyContinue | Out-Null | |
$outFile = """$outPath\$Name""" | |
Say that you want to cut out a part starting at 00:00:30 into the original file with a 5 seconds length and that it shouldn't be re-encoded (if you want to re-encode it you'll have to replace copy with audio and video codecs, for a list of available codecs issue ffmpeg -formats -E), then you issue:
ffmpeg -ss 00:00:30 -i orginalfile -t 00:00:05 -vcodec copy -acodec copy newfile
You'll have to replace orginalfile and newfile with actual file names, the later is the name of the file that is created to hold the cut out part.
OR - to set partial second start and shorter end, while dropping video and recode audio to MP3:
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
$ServerName = "SERVER" | |
$BackupDirectory = "D:\Backups\" | |
$BackupDate = get-date -format yyyyMMdd_HHmmss | |
[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SqlServer.SMO") | out-null | |
[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SqlServer.SmoExtended") | Out-Null | |
[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SqlServer.ConnectionInfo") | Out-Null | |
[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SqlServer.SmoEnum") | Out-Null | |
$ServerSMO = new-object ("Microsoft.SqlServer.Management.Smo.Server") $ServerName |
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 | |
/usr/share/voctomix-outcasts/ingest.py --custom-pipeline \ | |
"videotestsrc pattern=2 ! queue ! videoconvert ! videorate ! videoscale ! \ | |
video/x-raw,format=I420,width=1920,height=1080,framerate=30/1,pixel-aspect-ratio=1/1 ! \ | |
queue ! mux. \ | |
alsasrc name=audiosrc device=hw:CARD=QU32,DEV=0 provide-clock=false slave-method=re-timestamp ! \ | |
audio/x-raw,channels=32,layout=interleaved,rate=48000 ! queue ! \ | |
deinterleave name=d \ | |
interleave name=i \ |
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
#WORKING | |
gst-launch-1.0 tcpclientsrc host=127.0.0.1 port=15000 ! queue ! matroskademux name=d ! videoconvert ! videorate ! videoscale ! video/x-raw,width=1280,height=720,framerate=30/1 ! x264enc bitrate=4000 key-int-max=2 speed-preset=veryfast ! video/x-h264,profile=baseline ! h264parse ! queue ! flvmux name=mux d. ! audioresample ! audio/x-raw,rate=44100 ! queue ! voaacenc bitrate=128000 ! queue ! mux. mux. ! rtmpsink location="rtmp://rtmp-api.facebook.com:80/rtmp/<KEY>" | |