Flatten a nested directory tree into one folder without losing path context.
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
| /** | |
| * This script automates the process of deleting your own Instagram comments. | |
| * It deletes comments in batches to avoid hitting rate limits or breaking the page. | |
| * | |
| * WARNING: This function directly manipulates the DOM and depends on the current HTML | |
| * structure of Instagram's website to work. If Instagram implements changes to the | |
| * activity page layout, structure, or functionality, this script may break or cause | |
| * unexpected behavior. Use at your own risk and always review code before running it. | |
| * | |
| * How to use: |
To sign all your commits in the Git Pull Request (PR), you can use a combination of git rebase and git commit --amend. Here are the steps:
-
Before starting, make sure you've configured Git to use your signing key. You can do this with:
git config --global user.signingkey YOUR_SIGNING_KEY git config --global commit.gpgsign trueReplace
YOUR_SIGNING_KEYwith your GPG key ID. -
Then you need to start an interactive rebase with the parent of your first commit. If you don't know what commit that is, you can use
git logto display your commit history. Once you have your commit hash, start the rebase:
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
| <?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> | |
| <!-- not sure which one it is, so set both --> | |
| <key>Ensemble</key> | |
| <dict> | |
| <key>Enabled</key> | |
| <true/> | |
| </dict> |
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
| // Observe all notifications generated by the default NotificationCenter | |
| NotificationCenter.default.addObserver( | |
| forName: nil, object: nil, queue: nil) { notification in | |
| Swift.print("Notification: \(notification.name.rawValue), Object: \(notification.object)") | |
| } | |
| // Observe all notifications generated by the default DistributedNotificationCenter | |
| DistributedNotificationCenter.default().addObserver( | |
| forName: nil, object: nil, queue: nil) { notification in | |
| Swift.print("Notification: \(notification.name.rawValue), Object: \(notification.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
| { | |
| "extends": [ | |
| "eslint-config-react-app" | |
| ], | |
| "plugins": ["react", "import"], | |
| "rules": { | |
| "import/no-unresolved": "error" | |
| }, | |
| "settings": { | |
| "import/parsers": { |
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
| module.exports = { | |
| root: true, | |
| env: { | |
| node: true, | |
| }, | |
| parserOptions: { | |
| parser: "babel-eslint", | |
| }, | |
| settings: { | |
| 'import/resolver': 'webpack', |
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
| /* | |
| 1337 Translator | |
| "Leet" or "1337" is a popular alternative alphabet used by internet geeks. | |
| Create a translator function that takes a string and outputs that string translated to leet | |
| Leet Codex: | |
| A -> @ | |
| B -> 8 |
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
| #!/bin/bash | |
| # Generate a `:something-intensifies:` Slack emoji, given a reasonable image | |
| # input. I recommend grabbing an emoji from https://emojipedia.org/ | |
| set -euo pipefail | |
| # Number of frames of shaking | |
| count=10 | |
| # Max pixels to move while shaking |
NewerOlder