You can add all conventional comments Labels to Github as a saved replies by following the following steps:
- Go to https://github.com/settings/replies
- Open Developer Tools
- Copy/Paste above code in JavaScript console
- Press enter
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
| # Steps: | |
| # Create service file in /etc/systemd/system/puma.service | |
| # Reload systemd: systemctl daemon-reexec && systemctl daemon-reload | |
| # Enable service: systemctl enable puma.service | |
| # Start service: systemctl start puma.service | |
| # Check status: systemctl status puma.service | |
| # See service content: systemctl cat puma.service | |
| # Restart service (if updated): systemctl restart puma.service | |
| [Unit] |
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_THIS> to [UPDATE_THIS] | |
| find DIR -type f -exec perl -pi -e 's/(<)([A-Z]{1}[a-zA-Z]*_+[a-zA-Z_]*)(>)/[$2]/g' {} + | |
| # <[UPDATE_THIS]_STRING> to [[UPDATE_THIS]_STRING] | |
| find DIR -type f -exec perl -pi -e 's/(<)([A-Z\[]{1}[a-zA-Z\[\]]*_+[a-zA-Z_\[\]]*)(>)/[$2]/g' {} + | |
| # <AS3_REGION> to [AS3_REGION] | |
| find DIR -type f -exec perl -pi -e 's/(<)([A-Z\d\[]{1}[a-zA-Z\d\[\]]*_+[a-zA-Z_\d\[\]]*)(>)/[$2]/g' {} + | |
| # <[Evri_GB_client_name]_CA_[QA Team_AU_[QA Team_GB_[QA Team_HK_[QA Team_NL_[QA Team_SG_[QA Team_US_[IMPACT_PASSWORD]]]]]]]> |
Server Setup:
- Install composer
- composer require --dev deployer/deployer
- vendor/bin/dep init
- Setup Ubuntu LTS server
- Setup swap
- Create deploy user add to sudo group and remove password for sudo command
- Setup ssh key access (ssh without password)
- Generate new ssh key for deploy user
- Install nodejs LTS version
Install readline and openssl with standard brew install.
brew install readline
brew install openssl@1.1Set openssl env in ~/.zshrc..
Based on this tutorial but simplified and inlined. Particularly removed any Rails and 3rd party services part, assumed you just need deployment to any Ubuntu machine.
- A functional Rails app
- Hosted Git repository (Github, Bitbucket, Gitlab)
- Cloud hosting account (Digital Ocean, Vultr, Linode, Lightsail)
- Local SSH account
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
| # http_server.rb | |
| require 'socket' | |
| require 'rack' | |
| require 'rack/lobster' | |
| app = Rack::Lobster.new | |
| server = TCPServer.new 5678 | |
| while session = server.accept | |
| request = session.gets |
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 Business | |
| include Hashable | |
| include Stateable | |
| include Regexable | |
| include Mongoid::Document | |
| include Mongoid::Timestamps | |
| include AASM | |
| using StringRefinements |
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
| # Searchkick configuration | |
| searchkick word_middle: [ | |
| :name, :your_fields | |
| ], | |
| word_start: [ | |
| :name, :your_fields | |
| ] | |
| # Search | |
| fields = [ |