Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update library for purescript-contrib best practices #86

Merged
merged 9 commits into from
Aug 15, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# http://editorconfig.org
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.md]
trim_trailing_whitespace = false
19 changes: 19 additions & 0 deletions .github/ISSUE_TEMPLATE/bug-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
name: Bug report
about: Report an issue
title: ""
labels: bug
assignees: ""
---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
A minimal code example (preferably a runnable example on [Try PureScript](https://try.purescript.org)!) or steps to reproduce the issue.

**Expected behavior**
A clear and concise description of what you expected to happen.

**Additional context**
Add any other context about the problem here.
21 changes: 21 additions & 0 deletions .github/ISSUE_TEMPLATE/change-request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
name: Change request
about: Propose an improvement to this library
title: ""
labels: enhancement
assignees: ""
---

**Is your change request related to a problem? Please describe.**
A clear and concise description of what the problem is.

Examples:

- It's frustrating to have to [...]
- I was looking for a function to [...]

**Describe the solution you'd like**
A clear and concise description of what a good solution to you looks like, including any solutions you've already considered.

**Additional context**
Add any other context about the change request here.
54 changes: 20 additions & 34 deletions .github/contributing.md
Original file line number Diff line number Diff line change
@@ -1,51 +1,37 @@
# Contribution
# Contributing

Thank you for contributing to `purescript-argonaut-codecs`!
Thanks for your interest in contributing to argonaut-codecs! This file is a short, sweet introduction to contributing to this project. We ask that all new contributors read it before their first contribution to make sure we can get your work merged.

Following these guidelines helps ensure we're able to carefully consider your contribution and help you finalize your pull request. Your time (like ours) is valuable, and we try to at least provide constructive feedback on every contribution.
## Getting Started

### Contributions we love
`purescript-argonaut-codecs` is an open-source library and we love to receive contributions. There are many ways you can contribute:
### Do I belong here?

* Help expand our test coverage
* Help fix open issues, even if that simply means adding a helpful comment
* Help push along open pull requests that need more work to be complete
* Improve or add new usage examples to better demonstrate how to use the library in real-world scenarios
* Update documentation and tutorials to be easier to understand, more comprehensive, and above all -- up to date!
Everyone is welcome! People of all experience levels can join, begin contributing, and feel comfortable and safe making mistakes. People of all backgrounds belong here so long as they treat others with dignity and respect and do not harass, belittle, or insult others.

### Contributions we should discuss
Some contributions will take some discussion before we accept an update to the project. If your contribution includes one of the below examples (or seems to be reasonably similar), please consider reaching out to us before putting in a lot of work to build the feature. We're active on the [PureScript user forum](https://discourse.purescript.org/) and the [functional programming Slack](https://functionalprogramming.slack.com/) community (new? [use this link to join](https://fpchat-invite.herokuapp.com/)!). For feature requests, feel free to open an issue with a tag.
### What is the correct way to ask a question?

* New features and functions that will change the library's public API
* New tutorials (while we love seeing new tutorials, we won't always be able to feature them in the readme)
Feel free to ask questions by [opening an issue](https://github.com/purescript-contrib/purescript-argonaut-codecs/issues)! You can also ask questions on the [PureScript Discourse](https://discourse.purescript.org), or on the [Functional Programming Slack](https://functionalprogramming.slack.com) ([join](https://fpchat-invite.herokuapp.com)!) in the `#purescript` and `#purescript-beginners` channels.

# Ground Rules
### I'd like to help, how do I pick something to work on?

We have a small set of quality-of-life guidelines for contributing to `purescript-argonaut-codecs`. These include:
Any [open issue](https://github.com/purescript-contrib/purescript-argonaut-codecs/issues) that is not assigned to anyone is good to work on! If it's your first time contributing it's probably best to pick an issue marked [good first issue](https://github.com/purescript-contrib/purescript-argonaut-codecs/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue). You can also search for issues marked [help-wanted](https://github.com/purescript-contrib/purescript-argonaut-codecs/issues?q=is%3Aissue+is%3Aopen+label%3A%22help+wanted).

* All pull requests must pass continuous integration.
* If you are adding new functionality, you should provide tests and documentation for your code. If you're fixing an existing bug, please provide a failing test case your patch solves.
* If possible, please avoid requiring new dependencies.
The easiest way you can help is by contributing documentation (issues marked [document me](https://github.com/purescript-contrib/purescript-argonaut-codecs/issues?q=is%3Aissue+is%3Aopen+label%3A%22document+me). If you'd like to contribute documentation, we suggest [reading about the four kinds of documentation](https://documentation.divio.com).

### Filing issues
If you have a general question about the project, it's best to ask on the [PureScript user forum](https://discourse.purescript.org/) or the [functional programming Slack](https://functionalprogramming.slack.com/) than to open a new issue. If you have run into a bug in the project, then please do open an issue! When you do, we ask that you follow a few steps which are outlined in our issues template. The gist of it is here:
Your contribution can be as small as copy-pasting some instructions from an issue into the documentation! Everything is welcome.

* Verify the problem is indeed with `purescript-argonaut-codecs` (not with Pulp, Bower, or PureScript);
* Record what versions you are using for PureScript and `purescript-argonaut-codecs`
* Describe the issue with steps to reproduce (as much as you are able). A minimal reproducible example is the absolute best case scenario.
## Developing argonaut-codecs

We promise to address the issue as soon as we can.
All `purescript-contrib` libraries use recent versions of [PureScript](https://github.com/purescript/purescript), [Spago](https://github.com/purescript/spago), and [psa](https://github.com/natefaubion/purescript-psa). Any additional development dependencies can be installed via NPM and are listed in the `package.json` file for the repository.

### Suggesting features or enhancements
We love to hear about ways we could make better. If you're wishing for a feature that doesn't exist in `purescript-argonaut-codecs`, you're probably not alone; there are bound to be others with similar needs. Please feel free to open an issue on GitHub that describes:
### Proposing changes

* the feature you would like to see
* why you need it
* how it should work
If you would like to contribute code, tests, or documentation, please feel free to open a pull request for small changes. For large changes we recommend you first open an issue to propose your change and ensure that the maintainers are on board before you spend time implementing the change. We want to respect your time and effort. We can also assign the issue to you if you would like to make sure you're the one to work on it.

We promise to review your issue, but we aren't always able to accommodate all requests. It helps if you're able to contribute to the implementation, too!
### Merging changes

### Code reviews
The core team looks at pull requests weekly, at which point we will review your code, ensure it meets our ground rules and fits with the philosophy of the project, and -- if necessary -- provide constructive feedback. As soon as at least one member of the team has signed off on your pull request, we will merge your contribution.
All changes must happen through a pull request. Everyone with commit access can merge changes, though by convention we like to wait for two approvals for non-trivial changes. All pull requests must pass continuous integration; if the change adds new code we may also ask that you add a test.

If you opened a pull request and we need to ask a few questions, we expect responses within a month. After that we may close the pull request if it isn't showing any activity to keep things manageable.
## How do I get the "commit bit"?

If you'd like to take part in maintaining argonaut-codecs, just ask! We hand out the commit bit to folks who display sustained interest in the project. You can ask directly (for example: on Slack or via a DM on Discourse) or by opening an issue -- whichever you prefer!
22 changes: 0 additions & 22 deletions .github/issue_template.md

This file was deleted.

17 changes: 17 additions & 0 deletions .github/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Number of days of inactivity before an issue becomes stale
daysUntilStale: 90
# Number of days of inactivity before a stale issue is closed
daysUntilClose: 21
# Issues with these labels will never be considered stale
exemptLabels:
- pinned
- security
# Label to use when marking an issue as stale
staleLabel: wontfix
# Comment to post when marking an issue as stale. Set to `false` to disable
markComment: >
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.
# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: false
29 changes: 29 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: CI

on:
push:
branches: [master]
pull_request:
branches: [master]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: thomashoneyman/setup-purescript@main

- name: Cache PureScript dependencies
uses: actions/cache@v2
with:
key: ${{ runner.os }}-spago-${{ hashFiles('**/*.dhall') }}
path: |
.spago
output

- name: Build source
run: spago build

- name: Run tests
run: spago test --no-install
13 changes: 6 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
/.*
!/.gitignore
!/.github
!/.travis.yml
.*
!.gitignore
!.github
!.eslintrc.json
!.editorconfig

# Dependencies
bower_components
node_modules

# Generated files
output
dce-output
generated-docs

# Lockfiles
package-lock.json
# Non-NPM lockfiles
*.lock
20 changes: 0 additions & 20 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2015 PureScript Contrib
Copyright (c) 2020 PureScript Contrib

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
Loading