Files
Adam Fowler 9d11e1034a Replace scripts with common tools and git features (#18)
* Build devcontainer from features

* Fix lldb.library setting

* Remove Node.js comments

* Remove swift 4.2

* Update README

* Remove table from README

* Add test script

* comment
2023-02-15 19:18:51 +01:00

20 lines
779 B
Bash
Executable File

#!/bin/sh
# This script requires the devcontainer tool for publishing. You can install it with
# npm install -g @devcontainers/cli
# More details can be found here https://github.com/devcontainers/cli#try-it-out
#
# The script currently requires you to edit the devcontainer.json to replace the ${templateOption:imageVariant}
# with the swift version number you are testing with
template_id=swift
set -e
# Build container
echo "Building dev container"
id_label="test-container=${template_id}"
devcontainer up --id-label ${id_label} --workspace-folder "src/${template_id}/"
# Test swift runs
devcontainer exec --workspace-folder "src/${template_id}/" --id-label ${id_label} /bin/sh -c 'swift --version'
# Clean up
docker rm -f $(docker container ls -f "label=${id_label}" -q)