-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Switch localhost setup to vscode dev containers & update readme
- Loading branch information
1 parent
400ed0b
commit cfece2f
Showing
3 changed files
with
70 additions
and
11 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"name": "Jekyll", | ||
"image": "mcr.microsoft.com/devcontainers/jekyll:0-buster", | ||
"features": { | ||
"ghcr.io/devcontainers/features/node:1": { | ||
"version": "latest" | ||
} | ||
}, | ||
|
||
// Use 'forwardPorts' to make a list of ports inside the container available locally. | ||
"forwardPorts": [ | ||
// Jekyll server | ||
4000, | ||
// Live reload server | ||
35729 | ||
], | ||
|
||
// Use 'postCreateCommand' to run commands after the container is created. | ||
"postCreateCommand": "sh .devcontainer/post-create.sh" | ||
|
||
// Configure tool-specific properties. | ||
// "customizations": {}, | ||
|
||
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. | ||
// "remoteUser": "root" | ||
} |
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,22 @@ | ||
#!/bin/sh | ||
|
||
# Install the version of Bundler. | ||
if [ -f Gemfile.lock ] && grep "BUNDLED WITH" Gemfile.lock > /dev/null; then | ||
cat Gemfile.lock | tail -n 2 | grep -C2 "BUNDLED WITH" | tail -n 1 | xargs sudo gem install bundler -v | ||
fi | ||
|
||
# If there's a Gemfile, then run `bundle install` | ||
# It's assumed that the Gemfile will install Jekyll too | ||
if [ -f Gemfile ]; then | ||
bundle install | ||
fi | ||
|
||
yellow=$(tput setaf 3) | ||
normal=$(tput sgr0) | ||
|
||
printf "\n" | ||
printf "%40s\n" "${yellow}********************************************************************************" | ||
printf "%40s\n" "Don't forget to start the server after pressing any key to continue:" | ||
printf "%40s\n" "bundle exec jekyll serve" | ||
printf "%40s\n" "********************************************************************************${normal}" | ||
printf "\n" |
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