crystal-docker-quickstart

所属分类:Docker
开发工具:Makefile
文件大小:5KB
下载次数:0
上传日期:2023-05-22 00:44:50
上 传 者sh-1993
说明:  一个项目模板,用于在Docker容器中快速使用Crystal编程语言,无需安装...
(A project template for quickly working with the Crystal programming language in a Docker container, no installation needed.)

文件列表:
Dockerfile (627, 2023-09-25)
LICENSE (1099, 2023-09-25)
Makefile (730, 2023-09-25)
d_dev (713, 2023-09-25)
shard.lock (102, 2023-09-25)
shard.yml (84, 2023-09-25)
spec (0, 2023-09-25)
spec\hello_world_spec.cr (136, 2023-09-25)
spec\spec_helper.cr (15, 2023-09-25)
src (0, 2023-09-25)
src\main.cr (314, 2023-09-25)

# crystal-docker-quickstart **crystal-docker-quickstart** provides a project template for quickly working with the [Crystal programming language](https://crystal-lang.org/) in a container, with no installation necessary. ## Usage 1. (Fork and/or) clone this repository, and give it a name for your project: `git clone https://github.com/compumike/crystal-docker-quickstart.git my_app` 1. `cd my_app` 1. Run `./d_dev` to open a bash shell with a Docker container containing this directorye mounted in `/app/` (see source in `/app/src/`, unit tests in `/app/spec/`, and compiled output in `/app/out/`). Within the Docker container, you may run: ```shell # To run unit tests: make spec # To rebuild your compiled binary, which lives in /app/out/my_app make # To rebuild the binary, and run it: make && out/my_app ``` You may edit your source code from another terminal session or your favorite IDE. (The `d_dev` script mounts this directory into the container.) Good luck and enjoy! :) ## Next Steps You may wish to edit some configuration within `Dockerfile`, `d_dev`, or `Makefile`, for example to expose TCP ports, enable compiler release optimizations, or rename your binary to something other than `my_app`. If you'd like to incorporate a dependency, known as a "Shard" in the crystal world, first edit `shard.yml`, and then run `shards install` within the Docker container. ## Resources * [Tutorials](https://crystal-lang.org/reference/1.9/tutorials/basics/index.html) - novice * [Language Reference](https://crystal-lang.org/reference/1.9/syntax_and_semantics/index.html) - intermediate * [Standard Library Docs](https://crystal-lang.org/api/1.9.2/) - everyday reference material * [Docs Home](https://crystal-lang.org/reference/1.9/) * [Forum](https://forum.crystal-lang.org/)

近期下载者

相关文件


收藏者