Skip to content

Commit

Permalink
Remove bin/make_docs and move it to a Makefile.
Browse files Browse the repository at this point in the history
  • Loading branch information
hugopl committed Mar 11, 2022
1 parent 2335dfe commit a588444
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 17 deletions.
16 changes: 16 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
VERSION := $(shell cat shard.yml | grep "^version" | cut -d\ -f2)
.PHONY: doc

doc: bin/gi-crystal
@echo "Generating documentation for Gtk4.cr version $(VERSION)..."
./bin/gi-crystal
# We do this to avoid crystal doc generate links to generated files
echo " " >> LICENSE
crystal doc -s -p --project-name="GTK4.cr" --project-version="$(VERSION)" \
lib/gi-crystal/src/gi-crystal.cr \
lib/gi-crystal/src/auto/gtk-4.0/gtk.cr
# Put LICENSE file back
git checkout LICENSE

bin/gi-crystal:
shards install
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,7 @@ API docs can be found at https://hugopl.github.io/gtk4.cr/
To generate the documentation clone this repository then do:

```
shards install
./bin/gi-crystal
./bin/make-docs
$ make doc
```

The documentation will be found at `docs/index.html`.
Expand Down
14 changes: 0 additions & 14 deletions bin/make-docs

This file was deleted.

0 comments on commit a588444

Please sign in to comment.