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
| tasks.withType<Jar> { | |
| manifest { | |
| attributes["Main-Class"] = "com.example.MainKt" | |
| } | |
| } |
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
| Update (2022): https://gist.github.com/atyachin/2f7c6054c4cd6945397165a23623987d | |
| Steps for installing the Android Emulator from EC2 console: | |
| ----------------------------------------------------------- | |
| sudo apt install default-jdk | |
| wget https://dl.google.com/android/repository/sdk-tools-linux-4333796.zip | |
| unzip sdk-tools-linux-4333796.zip -d android-sdk | |
| sudo mv android-sdk /opt/ | |
| export ANDROID_SDK_ROOT=/opt/android-sdk |
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
| { | |
| "apps": [ | |
| { | |
| /* General */ | |
| "name": "my-api", /* (string) application name (default to script filename without extension) */ | |
| "script": "index.js", /* (string) script path relative to pm2 start */ | |
| "cwd": "/var/www/", /* (string) the directory from which your app will be launched */ | |
| "args": "-a 13 -b 12", /* (string) string containing all arguments passed via CLI to script */ | |
| "interpreter": "/usr/bin/python", /* (string) interpreter absolute path (default to node) */ | |
| "interpreter_args": "--harmony", /* (string) option to pass to the interpreter */ |
- Don't type or run anything until I told you so.
- This guide uses linux commands. For windows users, you can use
win-bash
I have one computer and two different github accounts. One is for work, the other is for my personal stuff. I can't use the same ssh key twice, so I have to use different ssh key for each of my accounts. How do I do that? How do I switch between these ssh keys?
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
| $ori = @{} | |
| Try { | |
| $i = 0 | |
| # Loading .env files | |
| if(Test-Path $args[0]) { | |
| foreach($line in (Get-Content $args[0])) { | |
| if($line -Match '^\s*$' -Or $line -Match '^#') { | |
| continue | |
| } |
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
| # Startup script for Ubuntu 17.04 VPS on Vultr (Dev machine and cloud server) | |
| # add a new user @todo: make this a one-liner | |
| # adduser stvhwrd | |
| # usermod -aG sudo stvhwrd | |
| ## MANUALLY LOG OUT AS ROOT AND LOG IN AS NEW USER | |
| # OPTIONAL: to add ssh key, assuming that you have ssh-copy-id installed on local machine and your keypair is in ~/.ssh and named id_rsa: | |
| # Locally, i.e. on your laptop. eg. ssh-copy-id stvhwrd@45.63.10.205 |
Next.js, Nginx with Reverse proxy, SSL certificate
- UPDATE (07/20/2021):
- This process got simplified over the years of this gist being out
- Older version of this gist (without certbot): https://gist.github.com/kocisov/2a9567eb51b83dfef48efce02ef3ab06/33fdd88872a0801bdde58fccce430fa48737ae10
- I would also now recommend deploying to Vercel if you don't need custom server support
Instructions to obtain ZSH on a windows environment, without the input funny business presented by some other attempted solutions.
The final result is ZSH running on a mintty terminal, emulated by cygwin, and being handled by the popular cmder.
For the benefit of myself and others. I've already followed these instructions twice. It took me hours to figure all this out, maybe someone else can save a few.
- Installing and setting up cmder