-
-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'release/2.4.27' into craft-webpack
- Loading branch information
Showing
11 changed files
with
73 additions
and
60 deletions.
There are no files selected for viewing
This file contains 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 file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
CONTAINER?=$(shell basename $(CURDIR))_php_1 | ||
|
||
.PHONY: build dev pulldb restoredb up | ||
|
||
build: up | ||
cd scripts/ && ./docker_prod_build.sh | ||
dev: up | ||
pulldb: up | ||
cd scripts/ && ./docker_pull_db.sh | ||
restoredb: up | ||
cd scripts/ && ./docker_restore_db.sh \ | ||
$(filter-out $@,$(MAKECMDGOALS)) | ||
up: | ||
if [ ! "$$(docker ps -q -f name=$${CONTAINER})" ]; then \ | ||
docker-compose up; \ | ||
fi | ||
%: | ||
@: | ||
# ref: https://stackoverflow.com/questions/6273608/how-to-pass-argument-to-makefile-from-command-line |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,7 @@ The project is based on [Craft CMS](https://CraftCMS.com) using a unique `templa | |
* [webpack 5](https://webpack.js.org/) is used for the build system as per [An Annotated webpack 4 Config for Frontend Web Development](https://nystudio107.com/blog/an-annotated-webpack-4-config-for-frontend-web-development) | ||
* [TypeScript](https://www.typescriptlang.org/) for strictly typed JavaScript code | ||
* [Vue.js 3.0](https://vuejs.org/) is used for some of the interactive bits on the website, and Vue.js 3.x allows us to leverage the [Composition API](https://composition-api.vuejs.org/) | ||
* [Tailwind CSS](https://tailwindcss.com/) for the site-wide CSS with CSS splitting as per the [Speeding Up Tailwind CSS Builds](https://nystudio107.com/blog/speeding-up-tailwind-css-builds) article | ||
* [Tailwind CSS](https://tailwindcss.com/) for the site-wide CSS using the [@tailwindcss/jit](https://blog.tailwindcss.com/just-in-time-the-next-generation-of-tailwind-css) | ||
* JSON-LD structured data as per [Annotated JSON-LD Structured Data Examples](https://nystudio107.com/blog/annotated-json-ld-structured-data-examples) | ||
* [Google AMP](https://developers.google.com/amp/) versions of the podcast episode and other pages | ||
* Image transforms are done via a [Serverless Image Handler](https://aws.amazon.com/solutions/serverless-image-handler/) lambda function, as described in the [Setting Up Your Own Image Transform Service](https://nystudio107.com/blog/setting-up-your-own-image-transform-service) article | ||
|
@@ -56,28 +56,30 @@ You'll need Docker desktop for your platform installed to run the project in loc | |
|
||
* Set up a `.env` file in the `cms/` directory, based off of the provided `example.env` | ||
* Set up a `.env.sh.` file in the `scripts/` directory, based off of the provided `example.env.sh` | ||
* Start up the site with `docker-compose up` (the first build will be somewhat lengthy) | ||
* Start up the site by typing `make dev` in terminal in the project's root directory (the first build will be somewhat lengthy) | ||
* Navigate to `http://localhost:8000` to use the site; the `webpack-dev-server` runs off of `http://localhost:8080` | ||
|
||
The CP login credentials are initially set as follows: | ||
|
||
Login: `[email protected]` \ | ||
Password: `letmein` | ||
|
||
Obviously change these to whatever you like as needed | ||
Obviously change these to whatever you like as needed. | ||
|
||
**N.B.:** Without authorization & credentials (which are private), the `./docker_pull_db.sh` will not work. It's provided here for instructional purposes | ||
Build the production assets by typing `make build` to build the critical CSS, fonts, and other production assets. They will appear in `cms/web/dist/` (just double-click on the `report-legacy.html` and `report-modern.html` files to view them). | ||
|
||
**N.B.:** Without authorization & credentials (which are private), the `make pulldb` will not work (it just runs `scripts/docker_pull_db.sh`). It's provided here for instructional purposes. | ||
|
||
To update to the latest Composer packages (as constrained by the `cms/composer.json` semvers), do: | ||
``` | ||
rm cms/composer.lock | ||
docker-compose up | ||
make dev | ||
``` | ||
|
||
To update to the latest npm packages (as constrained by the `buildchain/package.json` semvers), do: | ||
``` | ||
rm buildchain/package-lock.json | ||
docker-compose up | ||
make dev | ||
``` | ||
|
||
To use Xdebug with VSCode install the [PHP Debug extension](https://marketplace.visualstudio.com/items?itemName=felixfbecker.php-debug ) and use the following configuration in your `.vscode/launch.json`: | ||
|
This file contains 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 file contains 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 file contains 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 file contains 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 file contains 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 file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains 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