Standard escape codes are prefixed with Escape
:
- Ctrl-Key:
^[
- Octal:
\033
- Unicode:
\u001b
- Hexadecimal:
\x1B
- Decimal:
27
def normalize_volume(file) | |
output = `ffmpeg -i '#{file}' -af "volumedetect" -f null /dev/null 2>&1` | |
raise "Error getting audio volume from #{file} (#{$?})" unless $?.success? | |
max_volume = output.scan(/max_volume: ([\-\d\.]+) dB/).flatten.first | |
mean_volume = output.scan(/mean_volume: ([\-\d\.]+) dB/).flatten.first | |
return if !max_volume || !mean_volume | |
max_volume = max_volume.to_f | |
mean_volume = mean_volume.to_f | |
target_volume = -14.0 | |
adjustment = target_volume - mean_volume |
.\vs_buildtools.exe --passive --norestart --wait --add Microsoft.VisualStudio.Workload.VCTools --includeRecommended | Out-Default | |
$script = @' | |
$installdir = "$pwd" | |
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 | |
echo "Downloading cmake" | |
iwr https://cmake.org/files/v3.11/cmake-3.11.4-win64-x64.zip -OutFile cmake.zip | |
Expand-Archive cmake.zip -DestinationPath . |
#!/bin/sh -eu | |
LOCAL_PROJECT_PATH=${1-$PWD} | |
BUILD_COMMAND=" | |
shards build --static --release | |
chown 1000:1000 -R bin | |
" | |
INSTALL_CRYSTAL=" | |
echo '@edge http://dl-cdn.alpinelinux.org/alpine/edge/community' >>/etc/apk/repositories | |
apk add --update --no-cache --force-overwrite \ |