Below are the three most recent posts. To see a list of all posts, go here.
If I want to view the human-friendly HTML page for a pull request, I use this URL:
https://github.example.com/your-organization/your-repo/pull/12345
But if I want to view that same pull over the API, I have to use the plural pulls
:
https://github.example.com/api/v3/repos/your-organization/your-repo/pulls/12345
Why make it hard?
What’s wrong with this picture?
@host ~ $ curl -v -k "https://jenkins.stupid.internal.domain/jenkins/job/some-bullshit/buildWithParameters?foo=bar&token=REDACTED" 2>&1|grep Location
< Location: https://jenkins.stupid.internal.domain/queue/item/231369/
@host ~ $ curl -k https://jenkins.stupid.internal.domain/queue/item/231369/ 2>&1 |grep "< HTTP"
< HTTP/1.1 404 Not Found
@host ~ $
Seems like the URL you send back in a Location:
header should exist, right? Whoops, you have to know the Jenkins Secret Handshake to actually get what you want:
@host ~ $ curl -v -k "https://jenkins.stupid.internal.domain/queue/item/231408/api/json" 2>&1 | grep "< HTTP"
< HTTP/1.1 200 OK
Ok, filing that one away in my bin of tribal knowledge that is taking up so much space in by brain I can’t remember where my damn watch charger is.
Every. Goddamn. TIME. I try to figure out the version of a tool I’m using or try to run it with verbose output, I pick the wrong flag. Between -v
, -V
, --version
, --verbose
, and the god-forsaken -version
(looking at you Java), it seems to be evenly split across all packages based on my totally statistically significant sampling. GNU says that --version
should ALWAYS output the current version, but we all know how much developers love standards.
This site was inspired by the following quote:
"Thoreau says the mass of men lead lives of quiet desperation. Not programmers, though. They lead lives of really loud desperation." -Steve Yegge
Home - All posts - Contact - Atom feed - Last updated: 2023-12-28 20:44 UTC