Skip to content

Instantly share code, notes, and snippets.

@h0tcatSub
h0tcatSub / baccarat.py
Created May 13, 2024 07:55 — forked from FSXAC/baccarat.py
A simplified Baccarat game implemented in Python
# This is a python file to show how the game works
import random
CARDS = ['A', '2', '3', '4', '5', '6', '7', '8', '9', '10', 'J', 'Q', 'K']
VALUE = [1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 0, 0, 0]
OUTCOME = ['Player wins', 'Banker wins', 'Tie']
# Inclusive range function
irange = lambda start, end: range(start, end + 1)
@ttycelery
ttycelery / jingle-family-mart.txt
Last active May 13, 2024 07:55
Lirik Jingle Family Mart Lengkap 100%
// Transcribed manually from
// https://www.youtube.com/watch?v=GpUhmUVvD9Y
// Enjoy ;)
Hai kawan-kawan
Mari bekerja membangun bersama FamilyMart
Suka dan duka ada di FamilyMart
Semua keluarga kita
Mari menyapa pelanggan kita
@0ut0fcontrol
0ut0fcontrol / read_gz_file.py
Last active May 13, 2024 07:54
python read gzip(.gz) file line by line, compatible with python2 python3
import gzip
gzfile = "example.gz"
# using `with`
with gzip.open(gzfile) as f:
for i in f:
i = i.decode('utf-8') # for compatible with python3
#do sometime
print(i)
@ThioJoe
ThioJoe / cheat.bat
Last active May 13, 2024 07:53
"Cheat" Command Wrapper Script - Makes it easier to search specific terms with 'cheat' tool. Recommended to rename to "c.bat" for easy calling.
:: -----------------------------------------------------------------------------------------
:: Cheat Command Wrapper Script
:: -----------------------------------------------------------------------------------------
:: This batch script acts as a wrapper for 'cheat.exe', enhancing its functionality
:: by allowing more intuitive command-line interactions. Specifically, it:
::
:: 1. Directly accesses cheatsheets or tags with a single argument.
:: 2. Facilitates search within a cheatsheet using multiple arguments, treating them
:: as a single search query.
:: 3. Dynamically resolves the paths to the community and personal cheatsheets
@ThioJoe
ThioJoe / Error-Lookup-Tool-Friendly.bat
Last active May 13, 2024 07:53
Error Lookup Tool Friendly Output
@echo off
:: Note: Lines beginning with "REM" or :: are comments
:: Script by: https://github.com/thiojoe
:: Purpose: Creates a much more user friendly output for the Microsoft Error Lookup Tool (err.exe). It parses the original output and modifies the text.
:: Usage: Just call the batch file with command prompt along with the error code the same as you would with err.exe
:: Example: error.bat 50
:: Recommended to rename this script to something shorter like 'error.bat'. Must be next to the lookup tool exe file.
@v1mkss
v1mkss / JetBrains Activation.md
Last active May 13, 2024 07:53
JetBrains Activation

JetBrains Activation

  • No proxy for:
*.apache.org, *.github.com, *.github.io, *.githubusercontent.com, *.gitlab.com, *.google.com, *.gradle.org, *.jetbrains.space, *.maven.org, cache-redirector.jetbrains.com, cloudconfig.jetbrains.com, download-cdn.jetbrains.com, download.jetbrains.com, downloads.marketplace.jetbrains.com, ea-report.jetbrains.com, github.com, gitlab.com, google.com, gradle.org, jcenter.bintray.com, plugins.jetbrains.com, resources.jetbrains.com, www.jetbrains.com

Activation Key:

UX394X3HLT-eyJsaWNlbnNlSWQiOiJVWDM5NFgzSExUIiwibGljZW5zZWVOYW1lIjoiSG9uZ2lrIFVuaXZlcnNpdHntmY3snbXrjIDtlZnqtZAiLCJsaWNlbnNlZVR5cGUiOiJDTEFTU1JPT00iLCJhc3NpZ25lZU5hbWUiOiLkvJfliJvkupEg5bel5L2c5a6kIiwiYXNzaWduZWVFbWFpbCI6ImhhbmF6YXdhbWl0b0BnbWFpbC5jb20iLCJsaWNlbnNlUmVzdHJpY3Rpb24iOiJGb3IgZWR1Y2F0aW9uYWwgdXNlIG9ubHkiLCJjaGVja0NvbmN1cnJlbnRVc2UiOmZhbHNlLCJwcm9kdWN0cyI6W3siY29kZSI6IkdPIiwicGFpZFVwVG8iOiIyMDI0LTEyLTEzIiwiZXh0ZW5kZ
@juampynr
juampynr / CHANGELOG.md
Created March 27, 2018 09:35
Sample CHANGELOG

Change Log

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog and this project adheres to Semantic Versioning.

[Unreleased] - yyyy-mm-dd

Here we write upgrading notes for brands. It's a team effort to make them as

@jaburns
jaburns / _hello.asm
Created November 3, 2019 20:43
Win32 assembly hello messagebox
global _mainCRTStartup
extern _ExitProcess@4
extern _MessageBoxA@16 ; Value after @ is size of args on stack
section .text
_mainCRTStartup:
; Setup stack to give us 4 bytes to play with
; push ebp
; sub esp, 4
@gerry
gerry / decrypt_dbvis.py
Last active May 13, 2024 07:47
A quick hack to extract and decrypt credentials from DbVisualizer config files.
#!/usr/bin/env python
# decrypt_dbvis.py ~ gerry@twitter.com
# DbVisualizer uses PBEWithMD5AndDES with a static key to store passwords.
# This is a quick hack to extract and decrypt credentials from DbVisualizer config files.
# Tested against DbVisualizer Free 9.0.9 and 9.1.6
"""
[2014-03-25 02:05:30][not-the-sea workspace]$ security/p/gerry/misc/decrypt_dbvis.py
[+] DbVisualizer Password Extractor and Decryptor (@gerryeisenhaur)
[+] Additional Usage Options:
[+] security/p/gerry/misc/decrypt_dbvis.py <config filename>
@padeoe
padeoe / README_hfd.md
Last active May 13, 2024 07:45
CLI-Tool for download Huggingface models and datasets with aria2/wget+git

🤗Huggingface Model Downloader

Considering the lack of multi-threaded download support in the official huggingface-cli, and the inadequate error handling in hf_transfer, this command-line tool smartly utilizes wget or aria2 for LFS files and git clone for the rest.

Features

  • ⏯️ Resume from breakpoint: You can re-run it or Ctrl+C anytime.
  • 🚀 Multi-threaded Download: Utilize multiple threads to speed up the download process.
  • 🚫 File Exclusion: Use --exclude or --include to skip or specify files, save time for models with duplicate formats (e.g., *.bin or *.safetensors).
  • 🔐 Auth Support: For gated models that require Huggingface login, use --hf_username and --hf_token to authenticate.
  • 🪞 Mirror Site Support: Set up with HF_ENDPOINT environment variable.