Skip to content

Commit

Permalink
usage of alpine instead of ubuntu
Browse files Browse the repository at this point in the history
  • Loading branch information
lindt committed Nov 11, 2016
1 parent 323deef commit 90187cf
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 15 deletions.
21 changes: 12 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
FROM ruby
FROM frolvlad/alpine-oraclejdk8:slim

MAINTAINER [email protected]

# TODO: activate --ngram
RUN \
apt-get update && \
apt-get install -y unzip default-jre && \
gem install gherkin_language --no-format-exec && \
echo "Feature: Empty" > /tmp/empty.feature && \
gherkin_language /tmp/empty.feature && \
rm /tmp/empty.feature
RUN apk --update add ruby ruby-dev build-base ruby-rdoc ruby-irb ca-certificates openssl \
&& gem install gherkin_language json --no-format-exec \
&& echo "Feature: Empty" > /tmp/empty.feature \
&& gherkin_language /tmp/empty.feature \
&& rm /tmp/empty.feature \
&& apk del ruby-dev build-base ruby-rdoc ruby-irb ca-certificates openssl \
&& rm -rf /var/cache/apk \
&& ls -1 /tmp/LanguageTool*/org/languagetool/resource/ | grep -v en | xargs rm -rf /tmp/LanguageTool*/org/languagetool/resource/

CMD gherkin_language
ENTRYPOINT ["gherkin_language"]
CMD ["--help"]
17 changes: 11 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
Check Language of Gherkin Files
===============================
# Check Language of Gherkin Files

[![Build Status](https://travis-ci.org/funkwerk/gherkin_language.svg)](https://travis-ci.org/funkwerk/gherkin_language)
[![Latest Tag](https://img.shields.io/github/tag/funkwerk/gherkin_language.svg)](https://github.com/funkwerk/gherkin_language)

This tool analyzes the language of gherkin files and report language errors.
Currently just English is supported.

Usage
-----
## Usage

run `gherkin_language` on a list of files

Expand All @@ -29,9 +28,15 @@ By default it will accept unknown words. For warnings about unknown words add `-

Get a readability report using `--readability`. It indicates, which files are not good readable.

### Usage with Docker

Glossary
--------
Assuming there is a `test.feature` within the current folder, then the following command will check the feature file.

```
docker run -t -v $(pwd):/user -w /user gherkin/language test.feature
```

## Glossary

It happens that there are words which are unknown to the dictionary.
Once this happens think about if could use another word, that is more common. If there is no such word, add it to the directory-located glossary.

1 comment on commit 90187cf

@lindt
Copy link
Member Author

@lindt lindt commented on 90187cf Nov 30, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixes #2

Please sign in to comment.