Skip to content

Commit f5ff3cc

Browse files
authored
Merge pull request #97 from nestdotland/dev
0.3.0
2 parents 3484fbe + accbbd6 commit f5ff3cc

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+904
-623
lines changed

.eggignore

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
extends .gitignore
2+
.*ignore
3+
4+
# Extra typescript files
5+
test/
6+
*_test.ts
7+
Drakefile.ts
8+

.github/CODE_OF_CONDUCT.md

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
## Code of Conduct
2+
3+
### Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as
6+
contributors and maintainers pledge to making participation in our project and
7+
our community a harassment-free experience for everyone, regardless of age, body
8+
size, disability, ethnicity, gender identity and expression, level of experience,
9+
nationality, personal appearance, race, religion, or sexual identity and
10+
orientation.
11+
12+
### Our Standards
13+
14+
Examples of behaviour that contributes to creating a positive environment
15+
include:
16+
17+
- Using welcoming and inclusive language
18+
- Being respectful of differing viewpoints and experiences
19+
- Gracefully accepting constructive criticism
20+
- Focusing on what is best for the community
21+
- Showing empathy towards other community members
22+
23+
Examples of unacceptable behaviour by participants include:
24+
25+
- The use of sexualised language or imagery and unwelcome sexual attention or
26+
advances
27+
- Trolling, insulting/derogatory comments, and personal or political attacks
28+
- Public or private harassment
29+
- Publishing others' private information, such as a physical or electronic
30+
address, without explicit permission
31+
- Other conduct which could reasonably be considered inappropriate in a
32+
professional setting
33+
34+
### Our Responsibilities
35+
36+
Project maintainers are responsible for clarifying the standards of acceptable
37+
behaviour and are expected to take appropriate and fair corrective action in
38+
response to any instances of unacceptable behaviour.
39+
40+
Project maintainers have the right and responsibility to remove, edit, or
41+
reject comments, commits, code, wiki edits, issues, and other contributions
42+
that are not aligned to this Code of Conduct, or to ban temporarily or
43+
permanently any contributor for other behaviors that they deem inappropriate,
44+
threatening, offensive, or harmful.
45+
46+
### Scope
47+
48+
This Code of Conduct applies both within project spaces and in public spaces
49+
when an individual is representing the project or its community. Examples of
50+
representing a project or community include using an official project e-mail
51+
address, posting via an official social media account, or acting as an appointed
52+
representative at an online or offline event. Representation of a project may be
53+
further defined and clarified by project maintainers.
54+
55+
### Enforcement
56+
57+
Instances of abusive, harassing, or otherwise unacceptable behaviour may be
58+
reported by contacting the project team at support@nest.land. All
59+
complaints will be reviewed and investigated and will result in a response that
60+
is deemed necessary and appropriate to the circumstances. The project team is
61+
obligated to maintain confidentiality with regard to the reporter of an incident.
62+
Further details of specific enforcement policies may be posted separately.
63+
64+
Project maintainers who do not follow or enforce the Code of Conduct in good
65+
faith may face temporary or permanent repercussions as determined by other
66+
members of the project's leadership.
67+
68+
### Attribution
69+
70+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71+
available at [http://contributor-covenant.org/version/1/4][version]
72+
73+
[homepage]: http://contributor-covenant.org
74+
[version]: http://contributor-covenant.org/version/1/4/

.github/CONTRIBUTING.md

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
<p align="center">
2+
<img alt="GitHub issues" src="https://img.shields.io/github/issues-raw/nestdotland/eggs?logo=github">
3+
<img alt="GitHub closed issues" src="https://img.shields.io/github/issues-closed-raw/nestdotland/eggs?logo=github">
4+
<img alt="GitHub contributors" src="https://img.shields.io/github/contributors/nestdotland/eggs">
5+
</p>
6+
<p align="center">
7+
<a href="https://deno.land"><img src="https://img.shields.io/badge/-deno-gray?logo=deno" alt="Runtime"></a>
8+
<a href="https://www.typescriptlang.org/"><img src="https://img.shields.io/badge/-typescript-blue?logo=typescript" alt="language"></a>
9+
</p>
10+
11+
# Contributing / Developing
12+
13+
Contributions are welcome. Fork this repository and issue a pull request with your changes.
14+
15+
Please add new tests for new functionality, adapt the existing ones if needed, and make sure that `deno test` succeeds.
16+
17+
### Prerequisites
18+
You need to have [Git](https://git-scm.com/downloads) and [deno](https://deno.land) installed on your system.
19+
20+
### Setting up Dev
21+
Just execute these commands:
22+
23+
```shell
24+
git clone https://github.com/nestdotland/eggs.git
25+
cd eggs/
26+
```
27+
28+
This project uses drake to manage project scripts. Run it with Deno:
29+
```sh
30+
deno run -A Drakefile.ts
31+
# A shell alias shortcut can be set to run the default drakefile:
32+
alias drake="deno run -A Drakefile.ts"
33+
```
34+
35+
### Versioning
36+
37+
We use [SemVer](http://semver.org/) for versioning. For the versions available, see the [link to tags on this repository](/tags).
38+
39+
### Tests
40+
41+
```sh
42+
drake test
43+
```
44+
45+
### Style guide
46+
47+
```sh
48+
drake format
49+
drake lint
50+
```
51+
52+
Make sure to use [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/).
53+
54+
### Pull request
55+
56+
**Please PR to the `dev` branch!**
57+
Then follow the [pull request template](.github/PULL_REQUEST_TEMPLATE/pull_request.md).
58+
59+
### Deploying / Publishing
60+
61+
Submit a pull request after running `drake dev` to ensure it runs correctly.
62+
The module is automatically published to nest.land when a new release is published on github.
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<!-- Make sure you have read the contribution guide!
2+
https://github.com/nestdotland/template/tree/master/.github/CONTRIBUTING.md
3+
-->
4+
5+
# Description
6+
7+
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
8+
9+
Fixes # (issue)
10+
11+
## Type of change
12+
13+
Please delete options that are not relevant.
14+
15+
- [ ] Bug fix (non-breaking change which fixes an issue)
16+
- [ ] New feature (non-breaking change which adds functionality)
17+
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
18+
- [ ] This change requires a documentation update
19+
20+
# How Has This Been Tested?
21+
22+
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
23+
24+
- [ ] Test A
25+
- [ ] Test B
26+
27+
**Test Configuration**:
28+
* OS:
29+
* Version:
30+
31+
# Checklist:
32+
33+
- [ ] My code follows the style guidelines of this project
34+
- [ ] I have performed a self-review of my own code
35+
- [ ] I have commented my code, particularly in hard-to-understand areas
36+
- [ ] I have made corresponding changes to the documentation
37+
- [ ] My changes generate no new warnings
38+
- [ ] I have added tests that prove my fix is effective or that my feature works
39+
- [ ] New and existing unit tests pass locally with my changes

.github/workflows/lint.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,11 @@ jobs:
1616
- name: Setup Deno
1717
uses: denolib/setup-deno@v2
1818

19+
- name: Setup Drake
20+
run: deno run -A Drakefile.ts setup-github-actions
21+
1922
- name: Check formatting
20-
run: deno fmt --check
23+
run: drake check-format
2124

2225
lint:
2326
name: deno lint
@@ -31,6 +34,9 @@ jobs:
3134

3235
- name: Setup Deno
3336
uses: denolib/setup-deno@v2
37+
38+
- name: Setup Drake
39+
run: deno run -A Drakefile.ts setup-github-actions
3440

3541
- name: Run linter
36-
run: deno lint --unstable
42+
run: drake lint

.github/workflows/ship.yml

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,22 @@ on:
88
jobs:
99
release:
1010
runs-on: ubuntu-latest
11+
12+
env:
13+
NESTAPIKEY: ${{ secrets.NESTAPIKEY }}
14+
1115
steps:
1216
- name: Setup repo
1317
uses: actions/checkout@v2
1418

1519
- name: Setup Deno
1620
uses: denolib/setup-deno@v2
1721

22+
- name: Setup Drake
23+
run: deno run -A Drakefile.ts setup-github-actions
24+
1825
- name: Get eggs version
19-
run: |
20-
deno run ./src/version/printVersion.ts
21-
echo "::set-env name=EGGS_VERSION::$(deno run ./src/version/printVersion.ts)"
26+
run: drake get-version
2227

2328
- name: Draft release
2429
id: draft_release
@@ -30,8 +35,4 @@ jobs:
3035
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3136

3237
- name: Publish eggs
33-
# TODO(@oganexon): remove --description after next release
34-
run: |
35-
deno run -A --unstable mod.ts link ${{ secrets.NESTAPIKEY }}
36-
deno run -A --unstable mod.ts publish eggs --ignore "extends .gitignore" --version ${{ env.EGGS_VERSION }} --description "The CLI used to publish and update modules in nest.land."
37-
38+
run: drake ship

.github/workflows/test.yml

Lines changed: 18 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -18,27 +18,27 @@ jobs:
1818
matrix:
1919
os: [macOS-latest, windows-latest, ubuntu-latest]
2020

21+
env:
22+
NESTAPIKEY: ${{ secrets.NESTAPIKEY }}
23+
2124
steps:
2225
- name: Setup repo
2326
uses: actions/checkout@v2
2427

2528
- name: Setup Deno
2629
uses: denolib/setup-deno@v2
2730

28-
- name: Run tests
29-
run: deno test -A --unstable
31+
- name: Setup Drake
32+
run: deno run -A Drakefile.ts setup-github-actions
3033

31-
- name: Get eggs version
32-
run: |
33-
deno run ./src/version/printVersion.ts
34-
echo "::set-env name=EGGS_VERSION::$(deno run ./src/version/printVersion.ts)"
34+
- name: Run tests
35+
run: drake test
3536

3637
- name: Eggs release test
37-
run: |
38-
deno run -A --unstable mod.ts link ${{ secrets.NESTAPIKEY || 'null' }} -do
39-
deno run -A --unstable mod.ts publish eggs --dry-run -do --ignore "extends .gitignore" --version ${{ env.EGGS_VERSION }}
40-
41-
- uses: actions/upload-artifact@v2
38+
run: drake dry-ship
39+
40+
- name: Upload debug file
41+
uses: actions/upload-artifact@v2
4242
if: failure()
4343
with:
4444
name: eggs-debug
@@ -64,20 +64,17 @@ jobs:
6464
with:
6565
deno-version: nightly
6666

67-
- name: Run tests
68-
run: deno test -A --unstable
67+
- name: Setup Drake
68+
run: deno run -A Drakefile.ts setup-github-actions
6969

70-
- name: Get eggs version
71-
run: |
72-
deno run ./src/version/printVersion.ts
73-
echo "::set-env name=EGGS_VERSION::$(deno run ./src/version/printVersion.ts)"
70+
- name: Run tests
71+
run: drake test
7472

7573
- name: Eggs release test
76-
run: |
77-
deno run -A --unstable mod.ts link ${{ secrets.NESTAPIKEY || 'null' }} -do
78-
deno run -A --unstable mod.ts publish eggs --dry-run -do --ignore "extends .gitignore" --version ${{ env.EGGS_VERSION }}
74+
run: drake dry-ship
7975

80-
- uses: actions/upload-artifact@v2
76+
- name: Upload debug file
77+
uses: actions/upload-artifact@v2
8178
if: failure()
8279
with:
8380
name: eggs-debug

CHANGELOG.md

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)