| title | Docker Compose Cheatsheet |
|---|---|
| subtitle | Quick reference for Docker Compose commands and config files |
| author | Jon LaBelle |
| date | April 7, 2019 |
| source | https://jonlabelle.com/snippets/view/markdown/docker-compose-cheatsheet |
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
| # Find the latest version on https://github.com/creationix/nvm#install-script | |
| $ curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash | |
| # Add in your ~/.zshrc the following: | |
| export NVM_DIR=~/.nvm | |
| [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" | |
| $ source ~/.zshrc |
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
| # Insomnia Configuration | |
| ## Run the test query | |
| { | |
| shop { | |
| id | |
| name | |
| } | |
| } | |
| # Query Structure Examples |
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
| {% if checkout.total_price < 20000%} | |
| <style> | |
| .step__footer{ position: relative; padding-top: 35px; } | |
| .step__footer:before{ | |
| content: 'Minimum orders have to be over $200.00.'; | |
| position: absolute; | |
| top: 0; | |
| left: 0; | |
| font-size: 16px; | |
| text-align: center; |
- Text Content Generator - http://www.lipsum.com
- Favicon Generator - http://tools.dynamicdrive.com/favicon
- Data Generator - https://mockaroo.com/
- Mobile Mockup Generator - https://mockuphone.com
- Logo Generator - https://www.logaster.com
- UUID Generator - https://www.uuidgenerator.net/
- Hash Generator - https://passwordsgenerator.net/sha256-hash-generator/
- Ultimate Code Generator - https://webcode.tools/
- Go to your Shopify
admin/settings/filespage - Open your browser Dev tools, go to the console
Then, depending on the option you choose:
- Make sure your browser is set to download files automatically and doesn't ask for the download location every time
It's hard to migrate section themes that rely heavily on images. This bit of code helps you download all the CDN assets of your theme.
- Create a
cdn_assetsfolder - Create the
download_assets.jsfile at the root of your project - Edit the
download_assets.jsfile to match the path to your settings_data.json (line 3) - Edit the
download_assets.jsfile to set the "CDN code" of your store. Each file that you upload from/admin/settings/filesgets uploaded with the following format:https://cdn.shopify.com/s/files/1/YOUR_CDN_CODE/files/YOURFILE. The format of the code is/\d{4}\/\d{4}/(four digits, a forward slash, and four digits)
Migrations are a way to make database changes or updates, like creating or dropping tables, as well as updating a table with new columns with constraints via generated scripts. We can build these scripts via the command line using knex command line tool.
To learn more about migrations, check out this article on the different types of database migrations!
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
| <form action="/cart/add" method="post" enctype="multipart/form-data" id="AddToCartForm"> | |
| {% if collection.products_count > 0 %} | |
| {% for product in collection.products %} | |
| {% if product.available %} | |
| <div class="row"> | |
| <div class="col-xs-12 col-sm-4"> | |
| <img src="{{ product.image | default: product.featured_image | img_url: 'large' }}" alt="{{ variant.title | escape }}" /> | |
| </div> | |
| <div class="col-xs-12 col-sm-8" style="padding: 15% 40px 0"> | |
| <div class="col-xs-12 col-sm-12"> |
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 is your TEST dev theme [in Test env]. You should make all your changes here and view on test store while working. | |
| development: | |
| <<: *shared | |
| store: STORE_NAME_HERE.myshopify.com ## Test Store name. | |
| password: ADD_PASSWORD_HERE ## Private App password from Shopify. | |
| theme_id: 'ADD_THEME_ID_HERE' ## ID number of your Dev theme on live store. | |
| ## TEST Staging theme [in Test env] | |
| staging-test: | |
| <<: *shared |