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
git add xyz.rb | |
git commit -m "A meaningful change" | |
# NOTE: The job has a 5-second waiting period since there's a delay between pushing and creating a new "signoff" GitHub check status. | |
git push && gh signoff |
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
turbo:load # initial extension load | |
turbo:before-visit | |
turbo:before-fetch-request | |
turbo:visit # sends current URL to the server | |
turbo:before-fetch-response | |
turbo:before-cache | |
turbo:visit # server redirects to the appropriate url (based on the url) | |
turbo:load |
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
ELASTIC_PASSWORD=<your-elastic-password> | |
KIBANA_PASSWORD=<your-kibana-password> |
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
def expect_to_match_xml_fixture(xml, fixture_path) | |
expected = Nokogiri::XML(xml, &:noblanks).to_xml | |
fixture_path = Rails.root.join("spec/fixtures", fixture_path) | |
File.write(fixture_path, expected) if ENV["REPLACE_FIXTURE_SNAPSHOTS"] == "true" | |
actual = Nokogiri::XML(File.read(fixture_path), &:noblanks).to_xml | |
expect(expected).to eq(actual) | |
end |
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
[...document.querySelectorAll("a.yt-simple-endpoint.style-scope.ytd-playlist-video-renderer")].map(function(e) { return e.href; }) |
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
### Keybase proof | |
I hereby claim: | |
* I am miroslavcsonka on github. | |
* I am mcsonka (https://keybase.io/mcsonka) on keybase. | |
* I have a public key ASCxwlKD-VKxw1grZKSdRUCyttnCR4uZYFEUv9Zd_UmZ9go | |
To claim this, I am signing this object: |
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
[ | |
[[0, 0], [1, 0], [2, 0], [3, 0]], | |
[[0, 1], [1, 1], [2, 1], [3, 1]], | |
[[0, 2], [1, 2], [2, 2], [3, 2]], | |
[[0, 3], [1, 3], [2, 3], [3, 3]], | |
] | |
$rows = 4 | |
$columns = 4 |
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
case class With[+A, +B](a: A, b: B) | |
case class Pass[A](value: A) extends Result[A] | |
case class Fail(errors: List[String]) extends Result[Nothing] | |
sealed trait Result[+A] { | |
def and[B](that: Result[B]): Result[A With B] = (this, that) match { | |
case (Pass(a), Pass(b)) => Pass(With(a, b)) | |
case (Pass(_), Fail(e)) => Fail(e) |
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
class HashBuilder | |
def self.build &block | |
hb = HashBuilder.new | |
hb.instance_eval(&block) | |
hb.hash | |
end | |
attr_reader :hash |
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
kill -9 $(lsof -i tcp:3000 -t) |
NewerOlder