Skip to content

Commit

Permalink
Adding Earthly language (github-linguist#5613)
Browse files Browse the repository at this point in the history
* Adding Earthly and its Earthfiles

* Removing `.earthfile` extension

* Adding missing grammar license file

Co-authored-by: Colin Seymour <[email protected]>
  • Loading branch information
mccartney and lildude authored Nov 29, 2021
1 parent 5cf7ab4 commit 0669b8f
Show file tree
Hide file tree
Showing 7 changed files with 419 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,9 @@
[submodule "vendor/grammars/dylan.tmbundle"]
path = vendor/grammars/dylan.tmbundle
url = https://github.com/textmate/dylan.tmbundle
[submodule "vendor/grammars/earthfile-grammar"]
path = vendor/grammars/earthfile-grammar
url = https://github.com/earthly/earthfile-grammar.git
[submodule "vendor/grammars/ec.tmbundle"]
path = vendor/grammars/ec.tmbundle
url = https://github.com/ecere/ec.tmbundle
Expand Down
2 changes: 2 additions & 0 deletions grammars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,8 @@ vendor/grammars/dylan.tmbundle:
- source.dylan
- source.lid
- source.makegen
vendor/grammars/earthfile-grammar:
- source.earthfile
vendor/grammars/ec.tmbundle:
- source.c.ec
vendor/grammars/ecl-tmLanguage:
Expand Down
8 changes: 8 additions & 0 deletions lib/linguist/languages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1459,6 +1459,14 @@ Eagle:
codemirror_mode: xml
codemirror_mime_type: text/xml
language_id: 97
Earthly:
type: programming
color: "#2af0ff"
tm_scope: source.earthfile
ace_mode: text
filenames:
- Earthfile
language_id: 963512632
Easybuild:
type: data
color: "#069406"
Expand Down
21 changes: 21 additions & 0 deletions samples/Earthly/filenames/Earthfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
FROM openjdk:8-jdk-alpine
RUN apk add --update --no-cache gradle
WORKDIR /java-example

deps:
COPY build.gradle ./
RUN gradle build

build:
FROM +deps
COPY src src
RUN gradle build
RUN gradle install
SAVE ARTIFACT build/install/java-example/bin AS LOCAL build/bin
SAVE ARTIFACT build/install/java-example/lib AS LOCAL build/lib

docker:
COPY +build/bin bin
COPY +build/lib lib
ENTRYPOINT ["/java-example/bin/java-example"]
SAVE IMAGE --push earthly/examples:java
1 change: 1 addition & 0 deletions vendor/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ This is a list of grammars that Linguist selects to provide syntax highlighting
- **EJS:** [tree-sitter/tree-sitter-embedded-template](https://github.com/tree-sitter/tree-sitter-embedded-template) 🐌
- **EQ:** [dotnet/csharp-tmLanguage](https://github.com/dotnet/csharp-tmLanguage)
- **Eagle:** [textmate/xml.tmbundle](https://github.com/textmate/xml.tmbundle)
- **Earthly:** [earthly/earthfile-grammar](https://github.com/earthly/earthfile-grammar)
- **Easybuild:** [MagicStack/MagicPython](https://github.com/MagicStack/MagicPython)
- **Ecere Projects:** [Nixinova/NovaGrammars](https://github.com/Nixinova/NovaGrammars)
- **EditorConfig:** [sindresorhus/atom-editorconfig](https://github.com/sindresorhus/atom-editorconfig)
Expand Down
1 change: 1 addition & 0 deletions vendor/grammars/earthfile-grammar
Submodule earthfile-grammar added at 7e1511
Loading

0 comments on commit 0669b8f

Please sign in to comment.