Skip to content

Instantly share code, notes, and snippets.

View swmcc's full-sized avatar
👷‍♂️
Building things

Stephen McCullough swmcc

👷‍♂️
Building things
View GitHub Profile
@swmcc
swmcc / create_label.sh
Last active May 16, 2023 22:58
Creates a list of labels for a repo
gh label create "🐞 bug" --description "Something isn't working" --color d73a4a
gh label create "📚 documentation" --description "Improvements or additions to documentation" --color 0075ca
gh label create "\U0001f97d Testing" --description "Testing" --color bfdadc
gh label create "✨ enhancement" --description "New feature or request" --color a2eeef
gh label create "📦 project" --description "A project related issue" --color 0e8a16
gh label create "❓ question" --description "Further information is requested" --color d876e3
gh label create "👯\u200d♀️ duplicate" --description "This issue or pull request already exists" --color cfd3d7
gh label create "❌ wontfix" --description "This will not be worked on" --color ffffff
gh label create "🙏 help" --description "Extra attention is needed" --color 008672
gh label create "⛔️ invalid" --description "This doesn't seem right" --color e4e669
@swmcc
swmcc / keybase.md
Created October 1, 2019 10:56
key base file

Keybase proof

I hereby claim:

  • I am swmcc on github.
  • I am swmcc (https://keybase.io/swmcc) on keybase.
  • I have a public key ASBbACyzXjKYtoD4XJBvYQ2J6UUU5eZosMA3UHBLFES0Ogo

To claim this, I am signing this object:

<%= form_for(@post) do |f| %>
<%= f.collection_select(:category_id, Category.all, :id, :name, {prompt: "Choose a category" }) %><br>
<%= f.label :title %><br>
<%= f.text_field :title, placeholder: "Type the post title here" %><br>
<%= f.label :content %><br>
<%= f.text_area :content, size: "60x12", placeholder: "Type the post tect here" %><br>
<%= f.submit %>
<% end %>
<h1>Edit Post</h1>
<%= render ‘form’ %>
<%= link_to “Back”, root_path %>
<h1>New Post</h1>
<%= render ‘form’ %>
<%= link_to “Back”, root_path %>
<h1><%= @post.title %></h1>
<p><%= @post.content %></p>
<%= link_to "Edit", edit_post_path(@post) %>
<%= link_to "Delete", @post, method: :delete, data: { confirm: "Are you sure?" %>
<% @posts.each do |post| %>
<h1><%= link_to "post.title", post %></h1>
<p><%= post.content %></p>
<% end %>
#!/usr/bin/env ruby
output = `git log 2.20.1-rc1..develop --oneline --no-merges`
print output.split(/$/).map(&:strip)
@swmcc
swmcc / Guardfile
Created November 10, 2016 17:44
A boiler plate Guardfile for rspec and tmux
# A sample Guardfile
# More info at https://github.com/guard/guard#readme
## Uncomment and set this to only include directories you want to watch
# directories %w(app lib config test spec features) \
# .select{|d| Dir.exists?(d) ? d : UI.warning("Directory #{d} does not exist")}
## Note: if you are using the `directories` clause above and you are not
## watching the project directory ('.'), then you will want to move
## the Guardfile to a watched dir and symlink it back, e.g.
#!/usr/bin/env python
import glob
import struct
from boto.s3.connection import S3Connection
from multiprocessing.pool import ThreadPool
def files():
return glob.glob("tmp/inventory/*.gz")