This file contains hidden or 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 | |
| # Dependency: https://archive.org/services/docs/api/internetarchive/cli.html | |
| # Usage example: ./download.sh byte-magazine | |
| ia search "collection:$1" --itemlist | parallel 'ia download {} --glob="*.pdf"' |
This file contains hidden or 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
| mkdir -p woff && for f in *.ttf; do sfnt2woff "$f"; woff2_compress "$f"; done && mv *.woff* woff | |
This file contains hidden or 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
| /** | |
| * Parse takes a string and returns a nested array. The array nests | |
| * to a deeper level for each [[enclosed double bracket pair]]. | |
| * | |
| * eg: | |
| * | |
| * // Output: ['It goes ', ['deeper and ', ['deeper.']]] | |
| * parse('It goes [[deeper and [[deeper.]]]]'); | |
| */ | |
| function parse(str, startIdx = 0, isChild = false) { |
This file contains hidden or 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
| // These comparison functions only work for arrays with the following child types: | |
| // | |
| // - Arrays | |
| // - Values that can be directly compared with === | |
| // | |
| // If your array contains functions or objects, go away! | |
| // Solution 1: recursive comparison; 94 chars. | |
| let f=Array.isArray,c=(x,y)=>f(y)&&x.length==y.length&&x.every((a,i)=>f(a)?c(a,y[i]):a===y[i]) |
This file contains hidden or 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
| /* | |
| .m Masonry class | |
| .v Vertical align | |
| .s_ Size | |
| */ | |
| .s7 { | |
| font-size: var(--s7); | |
| } | |
| .v .s7 { | |
| line-height: 1.42606336em; |
This file contains hidden or 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
| console.log('20CEBA954FB7301896D'.split('').map(n => { | |
| const b = `segments.writeStream(0b${(1 << parseInt(n, 16)).toString(2)});`; | |
| return `blinkDots();\n${b}\n${b}\ndelay(100);\n`; | |
| }).join('')); |
This file contains hidden or 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
| const ENABLE_IMAGE_ROTATIONS = true; | |
| const ITERATIONS_PER_ROTATION = 10000000; | |
| const MAX_GATES_TOTAL = 20; | |
| const MAX_TREE_DEPTH = 6; | |
| const rand = array => array[Math.floor(Math.random() * array.length)]; | |
| const unique = (x, i, array) => array.indexOf(x) === i; | |
| const limit = (name, f, lo, hi = lo) => (...args) => { | |
| const { length: l } = args; | |
| if (l < lo || l > hi) |
This file contains hidden or 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 swap(str, a, b) { | |
| const ceil = str.length - 1; | |
| a = Math.min(Math.max(0, a), str.length - 1) || 0; | |
| b = Math.min(Math.max(0, b), ceil) || 0; | |
| if (a === b) return str; | |
| if (a > b) [a, b] = [b, a]; | |
| return ( | |
| str.slice(0, a) + str[b] + str.slice(a + 1, b) + str[a] + str.slice(b + 1) | |
| ); | |
| } |
This file contains hidden or 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
| From 66880db1f100c345004710deab0c28c54e035a1e Mon Sep 17 00:00:00 2001 | |
| From: Riley Shaw <rileyjshaw@gmail.com> | |
| Date: Mon, 8 Jun 2020 21:35:33 -0700 | |
| Subject: [PATCH] Merge remote-tracking branch 'upstream/gsoc' into | |
| layout/datasets-page | |
| --- | |
| web/locales/ast/messages.ftl | 10 +- | |
| web/locales/be/messages.ftl | 102 ++++++++++++++++++++- | |
| web/locales/ml/messages.ftl | 44 +++++++-- |
This file contains hidden or 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
| ffmpeg -i narration.mp3 -i original.mp4 -filter_complex "[0:a][1:a]amerge,pan=stereo|c0<c0+c2|c1<c1+c3[a]" -map 1:v -map "[a]" -c:v copy -c:a aac -shortest output.mp4 |