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
<noscript> | |
<style> | |
noscript section, | |
noscript section * { | |
box-sizing: border-box; | |
text-align: center; | |
font-size: 2rem; | |
} | |
noscript > section { |
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 | |
google_chrome_desktop_file="/usr/share/applications/google-chrome.desktop" | |
exec_directive="Exec=/usr/bin/google-chrome-stable" | |
dark_mode_flags="--enable-features=WebUIDarkMode --force-dark-mode" | |
replace_patterns="s#${exec_directive}#${exec_directive} ${dark_mode_flags}#g" | |
sed "${replace_patterns}" "${google_chrome_desktop_file}" | sudo tee "${google_chrome_desktop_file}" |
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 | |
# Instructions: | |
# Place this file inside /etc/NetworkManager/dispatcher.d/ | |
# sudo chown root:root 00_toggle-repo.sh | |
# sudo chmod +x 00_toggle-repo.sh | |
repos="rhel8-csb" |
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
#To Decrypt Jenkins Password from credentials.xml | |
#<username>jenkins</username> | |
#<passphrase>your-sercret-hash-S0SKVKUuFfUfrY3UhhUC3J</passphrase> | |
#go to the jenkins url | |
http://jenkins-host/script | |
#In the console paste the script | |
hashed_pw='your-sercret-hash-S0SKVKUuFfUfrY3UhhUC3J' |
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
interface MainFuncAsync { | |
(args: string[]): Promise<number|void> | |
} | |
class ProgramEntryPoint { | |
static main: MainFuncAsync; | |
} | |
interface IProgramEntryPoint { | |
new(): ProgramEntryPoint |
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 | |
SELF_SIGNED_CERTS_DIR="$PWD/.ssl" | |
[[ ! -d $SELF_SIGNED_CERTS_DIR ]] && mkdir $SELF_SIGNED_CERTS_DIR | |
rm -rf $SELF_SIGNED_CERTS_DIR/* | |
openssl req -newkey rsa:2048 -new -nodes \ | |
-keyout $SELF_SIGNED_CERTS_DIR/private-key.pem \ | |
-out $SELF_SIGNED_CERTS_DIR/csr.pem | |
openssl x509 -req -days 365 \ | |
-in $SELF_SIGNED_CERTS_DIR/csr.pem \ |
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 Spinner { | |
static #count = 0; | |
static #svgWrapperTemplate({ className, id, children }) { | |
return ` | |
<svg id="${id}" class="${className}" viewBox="0 0 100 100" preserveAspectRatio="xMidYMid"> | |
${children} | |
</svg> | |
`; | |
} |
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 letters = 'abcdefghijklmnopqrstuvwxyz'; | |
const numbers = '1234567890'; | |
const charset = letters + letters.toUpperCase() + numbers; | |
function pickRandomElement(array) { | |
const { floor, random } = Math; | |
return array[floor(random() * array.length)]; | |
} | |
function randomString(length) { |
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
ls ".\packages\*" -Include "build", "coverage", "dist", "node_modules" -Depth 2 | select FullName | % { rm -Recurse -Force -Verbose $_.FullName } |
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
public class Program { | |
internal class Node<T> { | |
final T data; | |
final Node<T> left; | |
final Node<T> right; | |
bool hasLeftChild() { | |
return this.left != null; | |
} |
NewerOlder