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 | |
| while $HOME/bin/clipnotify/clipnotify -s clipboard; | |
| do | |
| # selected_text="$(xsel)" | |
| copied_text="$(xsel -b)" | |
| # if [[ $selected_text != *"file:///"* ]]; then | |
| # modified_text_primary="$(echo "$selected_text" | tr -s '\n' ' ')" | |
| # echo -n "$modified_text_primary" | xsel -i | |
| # fi |
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
| import telegram.ext as telx | |
| import telegram as tel | |
| import logging | |
| from datetime import date as dt | |
| from pathlib import Path | |
| from shutil import copyfile | |
| """ | |
| Functionallity for Telegram bot that drops ledger entries. |
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 | |
| txt_files=`fd --type file -g '*.txt' -E blinky` | |
| c_files=`fd --type file -g '*.c' -E blinky` | |
| echo $c_files $txt_files | |
| # Set project specific build command. | |
| kak -s a $c_files -e "set-option global makecmd 'ninja -C build-firmware'" | |
| if [ $? != 0 ]; then | |
| kak -c a $c_files -e "set-option global makecmd 'ninja -C build-firmware'" |
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
| import sys | |
| import glob | |
| import re | |
| from pathlib import Path | |
| # https://github.com/xflr6/graphviz | |
| import graphviz | |
| DIR = sys.argv[1] |
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
| # get chat ID | |
| curl https://api.telegram.org/bot(pass tokens/telegram/my_bot)/getUpdates | jq .result[].message.chat | |
| # send message. 'chat_id' taken from previous step | |
| curl -X POST \ | |
| -H 'Content-Type: application/json' \ | |
| -d '{"chat_id": "486714429", "text": "test message from curl", "disable_notification": true}' \ | |
| https://api.telegram.org/bot(pass tokens/telegram/my_bot)/sendMessage |
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
| // ESP32 WROVER | |
| module copy_mirror(vec=[0,1,0]) | |
| { | |
| children(); | |
| mirror(vec) children(); | |
| } | |
| $fs = 0.3; |
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
| // Generate a simple PCB with mounting holes in the corners | |
| module copy_mirror(vec=[0,1,0]) | |
| { | |
| children(); | |
| mirror(vec) children(); | |
| } | |
| module rounded_box(width, length, height, radius){ | |
| hull(){ |