Skip to content

Instantly share code, notes, and snippets.

View DoodlingDev's full-sized avatar

Ajina Slater DoodlingDev

View GitHub Profile
@DoodlingDev
DoodlingDev / gist:369169afd559484584f88d8a4c3126e9
Last active February 2, 2024 13:04
Hotwire resources: from "Hotwiring my React Brain" Railsconf 2023
[Hotwire on the thoughtbot Blog](https://thoughtbot.com/blog/tags/hotwire)
[thoughtbot Hotwire Examples](https://github.com/thoughtbot/hotwire-example-template)
[Hotrails Turbo Rails Tutorial](https://www.hotrails.dev/turbo-rails)
[30 Days of Hotwire by @ilrock__ on Twitter](https://twitter.com/ilrock__/status/1631315562390519809)
[Code Sample Image Tool](https://www.snappify.com)
normalize_file = "./audio_normalize_results.txt"
system "touch #{normalize_file}"
files_list = Dir["./**/*"]
files_list = files_list.select do |n|
n.match(/\.mkv$/) ||
n.match(/\.mp4$/) ||
n.match(/\.avi$/)
end
@DoodlingDev
DoodlingDev / cloudSettings
Last active June 30, 2019 15:59
Visual Studio Code Settings Sync Gist
{"lastUpload":"2019-06-30T15:59:22.379Z","extensionVersion":"v3.3.1"}
# <type>: (If applied, this commit will...) <subject> (Max 50 char)
# |<---- Using a Maximum Of 50 Characters ---->|
# Explain why this change is being made
# |<---- Try To Limit Each Line to a Maximum Of 72 Characters ---->|
# Are there any gotchas or quirks for changing this code in the future?
# Provide links etc.. to any relevant articles or other resources
@DoodlingDev
DoodlingDev / pre-push js project hook
Last active February 16, 2018 05:33
Javascript pre-push commit hook
#!/bin/sh
check_exit_code () {
if [[ "${1}" -ne "0" ]]; then printf "{$2}"; exit 1; fi
}
RED=$(tput setaf 1)
WHITE=$(tput setaf 7)
GREEN=$(tput setaf 2)
NORMAL=$(tput sgr0)
@DoodlingDev
DoodlingDev / gist:c6723e78e5fa5b6c9ad5f7b955d68235
Last active November 19, 2018 02:49
States and Provinces for JavaScript
export const states = [
"Alabama",
"Alaska",
"American Samoa",
"Arizona",
"Arkansas",
"California",
"Colorado",
"Connecticut",
"Delaware",