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
| # Makefile: Convert Palm OS error codes into symbolic error names. | |
| # | |
| # Copyright (c) 2001 John Marshall. | |
| # | |
| # This is free software; you can redistribute it and/or modify it under the | |
| # terms of the GNU General Public License as published by the Free Software | |
| # Foundation; either version 2, or (at your option) any later version. | |
| # | |
| # This program is distributed in the hope that it will be useful, but | |
| # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY |
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 fish | |
| set DEPS 'autogen' 'base-devel' | |
| set YAYDEPS 'palm-os-sdk-git' | |
| set REPONAMEORDER 'pilrc-sc' 'prc-tools-sc' 'pilot-link-sc' 'jpilot-sc' | |
| sudo pacman -S --needed --noconfirm $DEPS |
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 | |
| HOST=fqdn.example.com | |
| PORT=8000 | |
| nc -z -w 5 "$HOST" "$PORT" && echo "Do this if the port is OPEN" || echo "Do this if the port is CLOSED" |
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 | |
| MAX_ATTEMPTS=120 | |
| if [[ -z "$1" ]]; then | |
| HOST="localhost" | |
| else | |
| HOST="$1" | |
| fi |
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 fish | |
| if test -f ".req.conf" | |
| rm .req.conf | |
| end | |
| set STRBASE "[req] | |
| distinguished_name = dn | |
| x509_extensions = v3_req | |
| prompt = no |
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 Get-RandomSuccess { | |
| $val = Get-Random -Maximum 2 | |
| $val -eq 0 | |
| } | |
| function Get-RandomThrow { | |
| if (!(Get-RandomSuccess)) { | |
| throw "ERR" | |
| } |
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
| class SwisConnection { | |
| [String] $HostName | |
| [Bool] $UseSSL | |
| [Bool] $ValidateSSL | |
| [Int] $Port | |
| [PSCredential] $Credential | |
| SwisConnection( | |
| [String] $HostName, | |
| [Bool] $UseSSL, |
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 { Worker, isMainThread, parentPort, workerData } = require('node:worker_threads'); | |
| const randIdx = vals => Math.floor(Math.random() * vals.length); | |
| const permute4 = vals => { | |
| const vCopy = [...vals]; | |
| if (vCopy.length !== 4) | |
| throw new Error('Array must be of size 4'); |
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 fetch = require("node-fetch"); | |
| const { readFileSync, writeFileSync } = require('fs'); | |
| const getAccess = async () => { | |
| const refresh_token = readFileSync('last_refresh', { encoding: 'utf-8' }); | |
| const data = new URLSearchParams(); | |
| data.append('refresh_token', refresh_token); | |
| data.append('grant_type', 'refresh_token'); |
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
| $TTL 60 | |
| $ORIGIN local.example.com. | |
| @ IN SOA examplecom.ddns.net. admin.example.com. {{SERIAL}} 300 900 604800 60 | |
| @ IN NS examplecom.ddns.net. | |
| @ IN A {{EXT_IP}} | |
| * IN CNAME examplecom.ddns.net. |
NewerOlder