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
# espanso match file | |
# For a complete introduction, visit the official docs at: https://espanso.org/docs/ | |
# You can use this file to define the base matches (aka snippets) | |
# that will be available in every application when using espanso. | |
# Matches are substitution rules: when you type the "trigger" string | |
# it gets replaced by the "replace" string. | |
matches: |
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
--[[ | |
Name: Touchpad Control | |
Author: James Doyle <james2doyle@gmail.com> | |
Description: Hook into events/gestures that are triggered on the trackpad | |
Installation: Just require this file in your Hammerspoon init.lua file | |
Usage: | |
Bind the click actions or swipe actions to events | |
]]-- | |
local trackpad_actions = {} |
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
! 2022-03-24 https://twitter.com | |
twitter.*##div[aria-label="Timeline: Trending now"] | |
twitter.*##div[aria-label="Home timeline"] > div > div article:has(div > div > div > span:has-text(Ad)) | |
! 2022-03-29 https://google.com | |
google.*##.g:has(a[href*="thetopsites.com"]) | |
google.*##.g:has(*:has-text(/bye topic of noninterest/i)) |
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 network | |
import utime | |
import socket | |
import machine | |
p2 = machine.Pin(2, machine.Pin.OUT) # create input pin on GPIO2 (builtin LED) | |
p2.off() | |
def toggle_pin(): | |
p2.value(1) if p2.value() == 0 else p2.value(0) |
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
// need to add the following to define the Serial class: | |
// #if defined(DEVELOP) | |
// extern HardwareSerial Serial; | |
// #endif | |
CompileFlags: | |
Add: [-xc++, -Wall, -DDEVELOP=1, -I$HOME/.platformio/packages/toolchain-atmelavr/avr/include/, -I$HOME/.platformio/packages/framework-arduino-avr/cores/arduino/, -I/Applications/Arduino.app/Contents/Java/hardware/tools/avr/lib/gcc/avr/7.3.0/include/, -I/Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/, -I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/, -I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/, -I/Applications/Arduino.app/Contents/Java/hardware/tools/avr/include/libiberty/, -I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/standard/, -I/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/variants/leonardo/, -I$HOME/.platformio/packages/toolchain-atmelavr/avr/include/avr/, -I$HOME/.platformio/packages/framework-arduino-avr/libraries/SoftwareSerial/src/, -I$HO |
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
--[[ | |
Name: Shortcuts (Toggle Apps/Shortcuts With The Keyboard) | |
Author: James Doyle <james2doyle@gmail.com> | |
Description: Run the shortcut that toggles apps and functions | |
Demo: <None> | |
Installation: Just require this file in your Hammerspoon init.lua file | |
Usage: | |
Press the keybinding | |
The shortcut/app will run or focus and there will be a notification | |
]]-- |
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
// Settings in here override those in "LSP-tailwindcss/LSP-tailwindcss.sublime-settings" | |
{ | |
"settings": { | |
"tailwindCSS.experimental.classRegex": [ | |
["classnames\\(([^)]*)\\)", "'([^']*)'"], | |
"class=\"([^\"]*)", // <div class="..." /> | |
"tw`([^`]*)", // tw`...` | |
"tw=\"([^\"]*)", // <div tw="..." /> | |
"tw={\"([^\"}]*)", // <div tw={"..."} /> | |
"tw\\.\\w+`([^`]*)", // tw.xxx`...` |
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
<?php | |
declare(strict_types=1); | |
use App\Models\User; | |
use Illuminate\Support\Facades\Artisan; | |
use Ramsey\Uuid\Rfc4122\Validator; | |
/* | |
|-------------------------------------------------------------------------- |
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
sudo apt-get update | |
sudo apt-get install lsb-release apt-transport-https ca-certificates | |
sudo wget -O /etc/apt/trusted.gpg.d/php.gpg https://origin.sury.org/php/apt.gpg | |
echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" | sudo tee /etc/apt/sources.list.d/php.list | |
sudo apt-get update | |
sudo apt-get install -y php8.1 php8.1-cli php8.1-cgi php8.1-swoole php8.1-intl php8.1-zip | |
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" | |
php -r "if (hash_file('sha384', 'composer-setup.php') === '55ce33d7678c5a611085589f1f3ddf8b3c52d662cd01d4ba75c0ee0459970c2200a51f492d557530c71c15d8dba01eae') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" | |
php composer-setup.php | |
sudo mv composer.phar /usr/local/bin/composer |
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
# For more options and information see | |
# http://rpf.io/configtxt | |
# Some settings may impact device functionality. See link above for details | |
# to disable unused network modules: | |
#dtoverlay=disable-wifi | |
#dtoverlay=disable-bt | |
# set the SSH terminal to use the connected screen on HDMI 0: export DISPLAY=:0.0 |