View RsyncBackup.js
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
#!/usr/bin/osascript -l JavaScript | |
// ^^^^ COMMENT/REMOVE THIS SHEBANG IF RUNNING FROM SCRIPT EDITOR!!!!! ^^^^^^^^^^^ | |
// The SHEBANG is only needed if the file is executable and is run from a terminal with `./RsyncBackup.js` | |
// 1. In MacOS Spotlight type 'Script Editor' and paste the code below | |
// 2. Click the top-left dropdown which says 'AppleScript' and select 'JavaScript' | |
// 3. Under menu File pick Export | |
// 4. In the Export dialog select File Format = Application | |
// 5. Save the app in /Applications |
View midnight-commander-build-macos.sh
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
brew install libssh libssh2 slang | |
clone --depth 1 https://github.com/MidnightCommander/mc.git | |
cd mc | |
./configure --disable-doxygen-doc --disable-doxygen-dot --disable-doxygen-html CPPFLAGS="-I/opt/homebrew/Cellar/libssh2/1.11.0_1/include -I/opt/homebrew/Cellar/s-lang/2.3.3/include -I/opt/X11/include" LDFLAGS="-L/opt/homebrew/Cellar/libssh2/1.11.0_1/lib -L/opt/homebrew/Cellar/s-lang/2.3.3/lib -L/opt/X11/lib" | |
make CPPFLAGS="-I/opt/homebrew/Cellar/libssh2/1.11.0_1/include -I/opt/homebrew/Cellar/s-lang/2.3.3/include -I/opt/X11/include" LDFLAGS="-L/opt/homebrew/Cellar/libssh2/1.11.0_1/lib -L/opt/homebrew/Cellar/s-lang/2.3.3/lib -L/opt/X11/lib" | |
sudo mkdir -p /usr/local/{libexec,etc,share} | |
sudo chown `whoami` /usr/local/{libexec,etc,share} |
View vimeo-download.py
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
#!/usr/bin/env python3 | |
import subprocess | |
import sys | |
from pathlib import Path | |
import requests | |
import base64 | |
from tqdm import tqdm |
View generate_directory_index_caddystyle.py
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
#!/usr/bin/env python3 | |
# NOTE: this script is deprecated; | |
# maintained version with SVG icons: https://github.com/glowinthedark/index-html-generator/ | |
# --- | |
# Copyright 2020 glowinthedark | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. |
View dict2mdx.sh
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 | |
# Convert Lingvo DSL, Babylon BGL, Stardict, ZIM, etc dictionaries to MDict MDX (see input formats supported by https://github.com/ilius/pyglossary) | |
# | |
# Dependencies: | |
# python3, sqlite3, pyglossary, mdict-utils | |
# optional dependency: dictzip (for unpacking .dz files) | |
# | |
# Install all dependencies with: | |
# pip3 install pyglossary mdict-utils lxml polib PyYAML beautifulsoup4 html5lib PyICU libzim>=1.0 python-lzo prompt_toolkit |
View scp-turbo-ssh-tar.sh
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
#!/usr/bin/env bash | |
# uses scp syntax e.g.: | |
# REMOTE -> LOCAL | |
# scp-turbo.sh myremote:/etc/apache2 /tmp/mylocal/dir | |
# | |
# LOCAL -> REMOTE | |
# scp-turbo.sh /tmp/mylocal/dir myremote:/home/user32/ | |
# see: >>>> https://www.cyberciti.biz/faq/howto-use-tar-command-through-network-over-ssh-session/ |
View ttc2ttf.sh
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
#!/usr/bin/env bash | |
# depends on: | |
# pip3 install fonttools | |
font="${1}" | |
for n in {1..10} ; do | |
echo $n | |
pyftsubset "${font}" --font-number=${n} \ |
View AsyncTask.java
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
package my.example.compat; | |
/* | |
* NOTICE: modified since 2023 and later. | |
* | |
* Copyright (C) 2008 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at |
NewerOlder