select name as username,
create_date,
modify_date,
type_desc as type,
authentication_type_desc as authentication_type
from sys.database_principals
where type not in ('A', 'G', 'R', 'X')
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 python3 | |
import argh | |
from PIL import Image | |
import argh | |
def convert(source_filename: str, destination_filename: str = "output.bin"): |
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
[alias] | |
# git jm "commit message" | |
# will add the Jira ticket ID (e.g.: PROJ-123) to your commit message | |
jm = "!f() { [[ $(git branch --show-current) =~ [A-Z]{2,}-[0-9]+ ]]; git commit -m \"${BASH_REMATCH[0]} ${1}\"; }; f" |
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
# Based on https://stackoverflow.com/a/31392574/14711510 | |
from pathlib import Path | |
import email | |
import email.utils as email_utils | |
import json | |
class EmailInfo: | |
def __init__(self, email_file: str) -> None: | |
email_file_path = Path(email_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
#!/usr/bin/env bash | |
RADIO_PATH="${HOME}/pyradio" | |
PLAYLIST=${RADIO_PATH}/playlist | |
mkdir -p ${RADIO_PATH} | |
curl -s https://gist.githubusercontent.com/DonBattery/78e21751ee5540984d6baca4a36eef2b/raw/playlist > ${PLAYLIST} | |
while true |
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
http://stream.klubradio.hu:8080/bpstream | |
https://stream.klubradio.hu:8443/bpstream |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<link rel="stylesheet" href="style.css"> | |
<title>Tanx</title> | |
</head> | |
<body> |
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
# based on: https://hub.docker.com/r/dduportal/docker-compose/dockerfile | |
# Usage | |
# set DOCKER_HOST to the remote machine | |
# copy your gcp_credfile.json to pwd | |
# $ docker build -t my-compose . | |
# $ docker run --rm -v /var/run/docker.sock:/var/run/docker.sock my-compose up -d --build --force-recreate |
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 -eou pipefail | |
GIMME_DIR="${HOME}/dev/gimme" | |
LEGAL_PROJ_TYPES=("go" "bash" "js" "py") | |
function usage { | |
echo " |
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
FROM golang AS builder | |
WORKDIR /app | |
COPY . . | |
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o my-app . | |
FROM alpine:latest |
NewerOlder