Skip to content

Commit

Permalink
readme: simplify readme, add overview, remove older examples
Browse files Browse the repository at this point in the history
resolve #28
  • Loading branch information
practicalli-johnny committed Apr 8, 2024
1 parent 98ceecf commit 15d4355
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 34 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ All notable changes to this project will be documented in this file. This change
## Changed
- dev: repository trivy ignore CVE-2024-22871
- service: move mulog publisher inside donut system config
- readme: simplify readme, add overview, remove older examples

# 2024-01-23
## Changed
Expand Down
67 changes: 33 additions & 34 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,41 +9,30 @@
╚═╝ ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝╚═╝ ╚═╝╚══════╝╚══════╝╚═╝
```

[![Latest Release](https://img.shields.io/github/v/release/practicalli/project-templates?display_name=tag)](https://github.com/practicalli/project-templates/releases)
## Overview

```clojure
io.github.practicalli/project-templates {:git/tag "2023-08-02" :git/sha "eaa11fa"}
```
Create new projects with a REPL driven development focus, including production level features where relevant. The templates are used by [deps-new](https://github.com/seancorfield/deps-new) via a user or project alias.

## Usage
Templates provide

Create a new project using the `:project/create` alias from [Practialli Clojure CLI Config](https://practical.li/clojure/clojure-cli/practicalli-config/), using `practicalli/minimal` template by default
- `:practicalli/minimal` essential tools, libraries and example code
- `:practicalli/service` production level web services with http-kit, reitit and swagger. Optional `:component` management with `:donut` or `:integrant`

```shell
clojure -T:project/create
```

Override the defaults used to create a project using command line options
## Configuration

* `:template` to specify a different template to create the project from, e.g. `:template practicalli/service`
* `:name` and value to create a project with a different name, e.g. `github-org/project-name`
* `:target-dir` to specify a directory to create the project in
* `:overwrite` an existing project with the same `:target-dir name`, `true` updates, `:delete` deletes existing project and replaces it with new project
[![Latest Release](https://img.shields.io/github/v/release/practicalli/project-templates?display_name=tag)](https://github.com/practicalli/project-templates/releases)

```shell
clojure -T:project/create :template practicalli/service \
:name practicalli/gameboard :target-dir gameboard-service
```clojure
io.github.practicalli/project-templates {:git/tag "2023-08-02" :git/sha "eaa11fa"}
```

### Alias definition
### Add alias

`:project/create` alias is provided by [Practialli Clojure CLI Config](https://practical.li/clojure/clojure-cli/practicalli-config/).
`:project/create` alias is provided by [Practicalli Clojure CLI Config](https://practical.li/clojure/clojure-cli/practicalli-config/).

The `project/create` alias definition combines [seancorfield/deps-new](https://github.com/seancorfield/deps-new) and practicalli/project-templates so that all Practicalli templates are available within one alias.

[![Latest Release](https://img.shields.io/github/v/release/practicalli/project-templates?display_name=tag)](https://github.com/practicalli/project-templates/releases) page includes the release `:git/tag` and `:git/sha` values for `io.github.practicalli/project-templates`


```clojure
:project/create
{:replace-deps {io.github.seancorfield/deps-new
Expand All @@ -55,18 +44,28 @@ The `project/create` alias definition combines [seancorfield/deps-new](https://g
:name practicalli/playground}}
```

> [seancorfield/deps-new](https://github.com/seancorfield/deps-new) can also be installed as a Clojure CLi tool, for example with the `project-create` tool name:
>
> ```bash
> clojure -Ttools install io.github.seancorfield/deps-new '{:git/tag "v0.5.2"}' \
> :as project-create
> ```
>
> Create a new project, specifying the template and name of the projects
>
> ```shell
> clojure -Tproject-create practicalli/service :name practicalli.gameboard/service
> ```
> [![Latest Release](https://img.shields.io/github/v/release/practicalli/project-templates?display_name=tag)](https://github.com/practicalli/project-templates/releases) page includes the release `:git/tag` and `:git/sha` values for `io.github.practicalli/project-templates`

## Usage

Create a new project using the `:project/create` alias from [Practicalli Clojure CLI Config](https://practical.li/clojure/clojure-cli/practicalli-config/), using `practicalli/minimal` template by default

```shell
clojure -T:project/create
```

Override the defaults used to create a project using command line options

* `:template` to specify a different template to create the project from, e.g. `:template practicalli/service`
* `:name` and value to create a project with a different name, e.g. `github-org/project-name`
* `:target-dir` to specify a directory to create the project in
* `:overwrite` an existing project with the same `:target-dir name`, `true` updates, `:delete` deletes existing project and replaces it with new project

```shell
clojure -T:project/create :template practicalli/service \
:name practicalli/gameboard :target-dir gameboard-service
```


## Templates Roadmap
Expand Down

0 comments on commit 15d4355

Please sign in to comment.