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 | |
| set -e | |
| ############################################################## | |
| # manage-secrets.sh - Encrypt & decrypt sensitive files | |
| # | |
| # Usage: | |
| # ./manage-secrets.sh enc [folder] [--keep|-k] Encrypt *.secret → *.secret.enc | |
| # ./manage-secrets.sh dec [folder] [--keep|-k] Decrypt *.secret.enc → *.secret | |
| # |
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
| # Create a folder for downloads | |
| $DownloadFolder = "$env:USERPROFILE\Downloads\LatestApps" | |
| New-Item -ItemType Directory -Path $DownloadFolder -Force | Out-Null | |
| # Create a log file | |
| $LogFile = "$DownloadFolder\download_log.txt" | |
| New-Item -ItemType File -Path $LogFile -Force | Out-Null | |
| Write-Host "Downloading files to: $DownloadFolder" | |
| Write-Host "Log file: $LogFile" | |
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 | |
| set -e | |
| ####################################### | |
| # Check if the script is running as root. | |
| # If not, use sudo for commands. | |
| ####################################### | |
| check_root() { | |
| if [ "$(id -u)" -eq 0 ]; then | |
| CMD_PREFIX="" |
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
| #!/usr/bin/env bash | |
| set -euo pipefail | |
| ### === Detect Privilege === ### | |
| if [[ "$(id -u)" -eq 0 ]]; then | |
| CMD_PREFIX="" | |
| else | |
| CMD_PREFIX="sudo" | |
| fi | |
| APT_CMD="$CMD_PREFIX apt-get" |
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
| @echo off | |
| setlocal EnableDelayedExpansion | |
| :: Entry point of the script | |
| call :requireAdmin || exit /b 1 | |
| call :logTask "Require Admin Privileges" | |
| call :checkInternet || exit /b 1 | |
| call :logTask "Check Internet Connection" | |
| call :checkAndSetup7Zip || exit /b 1 | |
| call :logTask "Check and Setup 7-Zip" |
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
| #!/usr/bin/env bash | |
| set -euo pipefail | |
| # ------------------------- Options & Help ------------------------- | |
| INSTALL_PKGS=1 | |
| SUDO_MODE="auto" # auto | never | always (always only for Linux apt) | |
| print_help() { | |
| cat <<USAGE | |
| Usage: $(basename "$0") [options] |
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
| pushd %temp% | |
| rd /q /s proxies >nul 2>&1 | |
| mkdir %temp%\proxies && cd /d %temp%\proxies && pushd %temp%\proxies && mkdir proxifly proxy-list >nul 2>&1 | |
| :: Proxifly | |
| curl -sL https://raw.githubusercontent.com/proxifly/free-proxy-list/main/proxies/all/data.txt -o proxifly\all.txt | |
| curl -sL https://raw.githubusercontent.com/proxifly/free-proxy-list/main/proxies/protocols/http/data.txt -o proxifly\http.txt | |
| curl -sL https://raw.githubusercontent.com/proxifly/free-proxy-list/main/proxies/protocols/socks4/data.txt -o proxifly\socks4.txt | |
| curl -sL https://raw.githubusercontent.com/proxifly/free-proxy-list/main/proxies/protocols/socks5/data.txt -o proxifly\socks5.txt | |
| curl -sL https://raw.githubusercontent.com/proxifly/free-proxy-list/main/proxies/countries/US/data.txt -o proxifly\socks5_US.txt |
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
| @echo off | |
| setlocal | |
| :: Check if required tools are installed | |
| dir "C:\Program Files\7-Zip\7z.exe" /b >nul || ( | |
| curl -fS -o %temp%\7z.msi https://www.7-zip.org/a/7z2408-x64.msi | |
| msiexec /i %temp%\7z.msi /quiet | |
| ) | |
| :: Check if rclone is installed |
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
| sudo docker run \ | |
| --init \ | |
| --sig-proxy=false \ | |
| --name nextcloud-aio-mastercontainer \ | |
| --restart always \ | |
| --publish 8080:8080 \ | |
| --env APACHE_PORT=11000 \ | |
| --env APACHE_IP_BINDING=0.0.0.0 \ | |
| --volume nextcloud_aio_mastercontainer:/mnt/docker-aio-config \ | |
| --volume /var/run/docker.sock:/var/run/docker.sock:ro \ |
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
| @echo off | |
| :: Define color codes | |
| set "RED=0c" | |
| set "YELLOW=0e" | |
| set "GREEN=0a" | |
| set "DEFAULT=07" | |
| :: Call setColor label to print text in different colors | |
| call :setColor "This is a red message" RED | |
| echo. |
NewerOlder