Skip to content

Instantly share code, notes, and snippets.

@kylemcdonald
kylemcdonald / matplotlib Border Removal.ipynb
Last active August 7, 2024 22:00
How to (mostly) remove all borders and padding with matplotlib.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@kestein
kestein / Private_Crates.md
Last active September 7, 2024 17:59
Linking to a private repo in Cargo.toml

Under the dependencies section, put

<crate name>={git="ssh://[email protected]/<organization>/<reponame>.git"}

It is pretty similar to a github repo's ssh cloning link, however the : is replaced with a / and ssh:// is prepended to the URL.

[email protected]:my-organization/my-repo.git vs ssh://[email protected]/my-organization/my-repo.git

The SSH URL needs to be used because Cargo is currently unable to handle the authentication prompt that comes up when an HTTPS link is used.
Make sure that the matches the crate name in the target repo's Cargo.toml. The repo name will not override what is in the Cargo.toml if it is a different value.

@brentjanderson
brentjanderson / Howto.md
Created February 20, 2018 17:55
SSH Tunneling with Firefox

Sometimes it is useful to route traffic through a different machine for testing or development. At work, we have a VPN to a remote facility that we haven't bothered to fix for routing, so the only way to access a certain machine over that VPN is via an SSH tunnel to a machine that is reachable over the VPN. Other times, I have used this technique to test internet-facing requests against sites I am developing. It is pretty easy, and if you don't use firefox regularly, you can treat Firefox as your "Proxy" browser and other browsers can use a normal configuration (Although you can also configure an entire system to use the proxy, other articles exists that discuss this potential).

  1. Open a terminal