loadkeys es
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
alias aliases="source ~/.bash_aliases" | |
# OS | |
alias poweroff="halt -p" | |
# Reboot and forever with No Gui | |
alias rebootNoGui='sudo systemctl set-default multi-user && sudo reboot' | |
# Reboot and forever with Gui |
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
import re | |
import socket | |
import struct | |
import platform | |
import subprocess | |
# https://stackoverflow.com/a/166589 | |
def getWANIP(): | |
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) | |
s.connect(("8.8.8.8", 80)) |
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
# Page settings | |
baseURL = "baseurl" | |
languageCode = "en" | |
title = "Hey! I'm using GA4" | |
[markup] | |
[markup.goldmark] | |
[markup.goldmark.renderer] | |
unsafe = true |
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
awful.keyboard.append_global_keybindings({ | |
-- Volume Control | |
-- https://bbs.archlinux.org/viewtopic.php?pid=958820#p958820 | |
awful.key({ }, "XF86AudioPlay", function () awful.util.spawn("mpc toggle") end), | |
awful.key({ }, "XF86AudioNext", function () awful.util.spawn("mpc next") end), | |
awful.key({ }, "XF86AudioPrev", function () awful.util.spawn("mpc prev") end), | |
awful.key({ }, "XF86AudioRaiseVolume", function () awful.util.spawn("amixer -c 0 set Master 1dB+") end), | |
awful.key({ }, "XF86AudioLowerVolume", function () awful.util.spawn("amixer -c 0 set Master 1dB-") end), | |
awful.key({ }, "XF86AudioMute", function () awful.util.spawn("amixer -c 0 set Master toggle") end), | |
}) |
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
from Crypto.Cipher import AES # Use cryptodome!! | |
import base64 | |
BS = 16 | |
pad = lambda s: s + (BS - len(s) % BS) * chr(BS - len(s) % BS).encode() | |
unpad = lambda s: s[:-ord(s[len(s)-1:])] | |
def iv(): | |
return chr(0) * 16 |
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
def randomPassword(length): | |
""" | |
pass = randomPassword(16) | |
Ref: https://stackoverflow.com/a/2257449 | |
""" | |
return(''.join(random.SystemRandom().choice(string.ascii_uppercase + string.digits) for _ in range(length))) | |
def _get_size(bytes: int, suffix="B"): | |
"""Scale bytes to its proper format. | |
e.g: |
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/python3 | |
############################################################################################### | |
# Author: n0nuser - Pablo Jesús González Rubio - https://nonuser.es - [email protected] | |
############################################################################################### | |
# | |
# Traverses files in a folder, executing the query in each file to a MS SQL Server | |
# | |
# If it succeeds, the file could be deleted | |
# | |
# If there's any error with a file (execution of query or not able to read file), |
This page is a recopilation of the following sources:
OlderNewer