mirror of
https://gitea.blesmrt.net/mikaela/scripts.git
synced 2025-08-20 21:37:20 +02:00
Compare commits
4 Commits
2a8d5e07c8
...
e0a8cc0e58
Author | SHA1 | Date | |
---|---|---|---|
e0a8cc0e58 | |||
b88027f81d | |||
1a58db1a6a | |||
907b1a425a |
@ -17,7 +17,7 @@ default_language_version:
|
|||||||
|
|
||||||
repos:
|
repos:
|
||||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||||
rev: v4.4.0
|
rev: v4.5.0
|
||||||
hooks:
|
hooks:
|
||||||
- id: check-added-large-files
|
- id: check-added-large-files
|
||||||
- id: check-case-conflict
|
- id: check-case-conflict
|
||||||
@ -30,6 +30,23 @@ repos:
|
|||||||
- id: fix-byte-order-marker
|
- id: fix-byte-order-marker
|
||||||
- id: trailing-whitespace
|
- id: trailing-whitespace
|
||||||
exclude_types: [markdown]
|
exclude_types: [markdown]
|
||||||
|
- id: check-docstring-first
|
||||||
|
#- id: check-json
|
||||||
|
- id: check-merge-conflict
|
||||||
|
#- id: check-toml
|
||||||
|
#- id: check-xml
|
||||||
|
- id: debug-statements
|
||||||
|
- id: fix-encoding-pragma
|
||||||
|
args: [--remove]
|
||||||
|
- id: mixed-line-ending
|
||||||
|
# .gitattributes is trusted to handle this
|
||||||
|
args: [--fix=no]
|
||||||
|
#- id: pretty-format-json
|
||||||
|
#- id: requirements-txt-fixer
|
||||||
|
- repo: https://github.com/pre-commit-ci/pre-commit-ci-config
|
||||||
|
rev: v1.6.1
|
||||||
|
hooks:
|
||||||
|
- id: check-pre-commit-ci-config
|
||||||
- repo: https://github.com/thlorenz/doctoc
|
- repo: https://github.com/thlorenz/doctoc
|
||||||
rev: v2.2.0
|
rev: v2.2.0
|
||||||
hooks:
|
hooks:
|
||||||
@ -40,6 +57,18 @@ repos:
|
|||||||
rev: "v1.5.1"
|
rev: "v1.5.1"
|
||||||
hooks:
|
hooks:
|
||||||
- id: mypy
|
- id: mypy
|
||||||
|
- repo: https://github.com/asottile/pyupgrade
|
||||||
|
rev: v3.15.0
|
||||||
|
hooks:
|
||||||
|
- id: pyupgrade
|
||||||
|
- repo: https://github.com/asottile/reorder-python-imports
|
||||||
|
rev: v3.12.0
|
||||||
|
hooks:
|
||||||
|
- id: reorder-python-imports
|
||||||
|
- repo: https://github.com/asottile/add-trailing-comma
|
||||||
|
rev: v3.1.0
|
||||||
|
hooks:
|
||||||
|
- id: add-trailing-comma
|
||||||
- repo: https://github.com/pre-commit/mirrors-prettier
|
- repo: https://github.com/pre-commit/mirrors-prettier
|
||||||
rev: "v3.0.3"
|
rev: "v3.0.3"
|
||||||
hooks:
|
hooks:
|
||||||
|
17
bash/usr-local-bin/meld
Executable file
17
bash/usr-local-bin/meld
Executable file
@ -0,0 +1,17 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
# In case we are on SteamOS?
|
||||||
|
#set -x
|
||||||
|
# The usual system-wide installation
|
||||||
|
if [ -f /usr/bin/meld ]; then
|
||||||
|
/usr/bin/meld $@
|
||||||
|
# System-wide flatpak
|
||||||
|
elif [ -f /var/lib/flatpak/exports/bin/org.gnome.meld ]; then
|
||||||
|
flatpak run org.gnome.meld $@
|
||||||
|
# User-specific flatpak
|
||||||
|
elif [ -f ~/.local/share/flatpak/exports/bin/org.gnome.meld ]; then
|
||||||
|
flatpak run --user org.gnome.meld $@
|
||||||
|
# If not found.
|
||||||
|
else
|
||||||
|
printf "meld doesn't seem to be installed :("
|
||||||
|
fi
|
||||||
|
#set +x
|
@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
import sys
|
|
||||||
import secrets
|
import secrets
|
||||||
|
import sys
|
||||||
|
|
||||||
try:
|
try:
|
||||||
wantedCount = int(sys.argv[1])
|
wantedCount = int(sys.argv[1])
|
||||||
|
@ -1,16 +1,14 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
"""
|
"""
|
||||||
This script asks for a SSID name, counts it and tells whether it's of valid
|
This script asks for a SSID name, counts it and tells whether it's of valid
|
||||||
length
|
length
|
||||||
"""
|
"""
|
||||||
|
|
||||||
# Request input or assume "test" on empty.
|
# Request input or assume "test" on empty.
|
||||||
givenssid = str(
|
givenssid = str(
|
||||||
input(
|
input(
|
||||||
"Please enter the SSID you are thinking of (preferably 26 chars to fit _nomap): "
|
"Please enter the SSID you are thinking of (preferably 26 chars to fit _nomap): ",
|
||||||
)
|
)
|
||||||
or "test"
|
or "test",
|
||||||
)
|
)
|
||||||
|
|
||||||
# Ensure it's UTF-8 and store the size. E.g. åäö are longer than oao
|
# Ensure it's UTF-8 and store the size. E.g. åäö are longer than oao
|
||||||
|
Loading…
x
Reference in New Issue
Block a user