Skip to content

Instantly share code, notes, and snippets.

View hahwul's full-sized avatar
🔥
I love coffee ☕️

HAHWUL hahwul

🔥
I love coffee ☕️
View GitHub Profile
@hahwul
hahwul / proxy-switcher.plist
Created October 31, 2023 04:01
proxy-switcher
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>PayloadContent</key>
<array>
<dict>
<key>PayloadDescription</key>
<string>Enable proxy settings for ZAP</string>
<key>PayloadDisplayName</key>
@hahwul
hahwul / solid_queue_tips.rb
Last active February 16, 2024 04:36
solid_queue tips
# Get all workers
SolidQueue::Process.all
# Get Pause and Ready Job
SolidQueue::Pause.all.pluck(:queue_name)
SolidQueue::ReadyExecution.where("queue_name LIKE ?", "dc_development_%").distinct(:queue_name).pluck(:queue_name)
# Get Failed Job
SolidQueue::FailedExecution.all
SolidQueue::FailedExecution.count
@hahwul
hahwul / code-line.sh
Created February 15, 2024 10:18
code line
git ls-files | xargs cat | wc -l
@hahwul
hahwul / create-heading-links.js
Created February 24, 2024 12:52
Create Heading Links
@hahwul
hahwul / index.html.erb
Created February 29, 2024 07:48
rails-charts(echarts) auto-resizing
<%= area_chart Rails.cache.read("data1") %>
<%= area_chart Rails.cache.read("data2") %>
<%= area_chart Rails.cache.read("data3") %>
<script>
let eChartTriggerList = document.querySelectorAll('[id^="rails_charts_"]')
window.addEventListener('resize', function() {
let eChartList = [...eChartTriggerList].map(eChartTriggerEl => echarts.init(eChartTriggerEl).resize())
});
</script>