From 7bd8a8d5da87493edfa1a2b3e95b7f2e95e39c29 Mon Sep 17 00:00:00 2001 From: Oliver Steele Date: Wed, 5 Jul 2017 13:56:19 -0400 Subject: [PATCH] GitHub templates --- .github/ISSUE_TEMPLATE.md | 14 ++++++++++++++ .github/PULL_REQUEST_TEMPLATE.md | 8 ++++++++ CONTRIBUTING.md | 11 ++++++----- README.md | 20 +++++++++++++++++++- 4 files changed, 47 insertions(+), 6 deletions(-) create mode 100644 .github/ISSUE_TEMPLATE.md create mode 100644 .github/PULL_REQUEST_TEMPLATE.md diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 0000000..8dd802a --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -0,0 +1,14 @@ +## Checklist + +- [ ] I have searched the [issue list](https://github.com/osteele/liquid/issues) +- [ ] I have read the [status](https://github.com/osteele/gojekyll#status) section of the README. This isn't a duplicate of something that's already on the roadmap. +- [ ] I have ready the [other differences](https://github.com/osteele/gojekyll#status) section of the README. +- [ ] I have tested my example against Shopify Liquid. (Not necessary for a panic or stack trace. These should never happen.) + +## Expected Behavior + +## Actual Behavior + +## Detailed Description + +## Possible Solution diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 0000000..3ada58d --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,8 @@ +## Checklist + +- [ ] I have read the contribution guidelines. +- [ ] `make test` passes. +- [ ] `make lint` passes. +- [ ] New and changed code is covered by tests. +- [ ] Performance improvements include benchmarks. +- [ ] Changes match the *documented* (not just the *implemented*) behavior of Shopify. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 1dc70aa..8ec33df 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,13 +1,14 @@ # Contributing -Refer to the [(original) Liquid contribution guidelines](https://github.com/Shopify/liquid/blob/master/CONTRIBUTING.md). +Here's some ways to help: -In addition to those checklists, I also won't merge: +* Pick an un-checked item from [Status](https://github.com/osteele/liquid#status). Let me know you want to work on it – I have ideas for some of these. +* Search the source for FIXME and TODO. Tackle one of them. +* Improve the [code coverage](https://coveralls.io/github/osteele/liquid?branch=master). -- [ ] Performance improvements that don't include a benchmark. -- [ ] Meager (<3%) performance improvements that increase code verbosity or complexity. +Review the [pull request template](https://github.com/osteele/liquid/blob/master/.github/PULL_REQUEST_TEMPLATE.md) before you get too far along on coding. -A caveat: The cyclomatic complexity checks on generated functions, hand-written parsers, and some of the generic interpreter functions, have been disabled (via `nolint: gocyclo`). IMO this check isn't appropriate for those classes of functions. This isn't a license to disable cyclomatic complexity or lint in general. +A note on lint: `nolint: gocyclo` has been used to disable cyclomatic complexity checks on generated functions, hand-written parsers, and some of the generic interpreter functions. IMO this check isn't appropriate for those classes of functions. This isn't a license to disable cyclomatic complexity checks or lint in general. ## Cookbook diff --git a/README.md b/README.md index 9214a23..0bbf0d5 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,7 @@ - [Go Liquid Template Parser](#go-liquid-template-parser) - [Status](#status) + - [Other Differences](#other-differences) - [Install](#install) - [Contributing](#contributing) - [References](#references) @@ -28,7 +29,7 @@ ## Status -This library is in early development. The API may still change. +This library is in early development. There's probably lots of corner cases, and the API (especially around defining tags) may still change. - [ ] Basics - [x] Literals @@ -44,6 +45,7 @@ This library is in early development. The API may still change. - [x] `unless` - [x] `case` - [x] `when` + - [ ] `when a or b` - [ ] `else` - [ ] Iteration - [x] modifiers (`limit`, `reversed`, `offset`) @@ -62,6 +64,22 @@ This library is in early development. The API may still change. - [x] everything else - [x] Drops +## Other Differences + +These will change: + +* I haven't investigated the interaction of loop reversed, limit, and offset, and whether it matters which order they're specified, in Shopify Liquid. +* This implementation doesn't parse very many date formats. I have any idea for this; talk to me if you're interested in implementing it. +* Identifiers can include hyphens. +* `contains` isn't implemented on hashes. +* `contains` doesn't stringify its argument. +* The `nil` constant isn't implemented. + +These might not: + +* This parser accepts parentheses in places where Shopify Liquid does not. +* `else` and `elsif` work inside of `unless` + ## Install `go get -u github.com/osteele/goliquid`