Skip to content

Commit

Permalink
feat: version 2.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
santi100a committed Sep 23, 2023
1 parent f82d681 commit 757cd5c
Show file tree
Hide file tree
Showing 113 changed files with 5,727 additions and 8,098 deletions.
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
cjs
node_modules
43 changes: 20 additions & 23 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,25 +1,22 @@
{
"env": {
"browser": true,
"commonjs": true,
"es2021": true,
"node": true
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:jest/recommended"
],
"overrides": [
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": "latest"
},
"plugins": [
"@typescript-eslint"
],
"rules": {
"@typescript-eslint/no-var-requires": "off"
}
"env": {
"browser": true,
"commonjs": true,
"es2021": true,
"node": true
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:jest/recommended"
],
"overrides": [],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": "latest"
},
"plugins": ["@typescript-eslint"],
"rules": {
"@typescript-eslint/no-var-requires": "off"
}
}
2 changes: 1 addition & 1 deletion .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
github: santi100a
github: santi100a
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ updates:
- package-ecosystem: npm # See documentation for possible values
directory: / # Location of package manifests
schedule:
interval: weekly
interval: weekly
2 changes: 1 addition & 1 deletion .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
'CI failed': '**/*.*'
'CI failed': '**/*.*'
2 changes: 1 addition & 1 deletion .github/workflows/check-md-links.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ jobs:
node-version: 19.x
- name: Install dependencies
run: yarn
- name: Run link check
- name: Run link check
run: yarn check-links
35 changes: 18 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,43 +22,42 @@ jobs:
- name: Check commit message
id: commit
run: |
COMMIT_MSG=$(/usr/bin/git log --format=%B -n 1 HEAD)
STRING=$(echo $COMMIT_MSG | (grep -E "infra:|docs:|lint:|code-style:" || echo ''))
COMMIT_MSG=$(/usr/bin/git log --format=%B -n 1 HEAD)
STRING=$(echo $COMMIT_MSG | (grep -E "infra:|docs:|lint:|code-style:" || echo ''))
if [ -z "$STRING" ]; then
echo "IS_RELEASE_COMMIT=1" >> $GITHUB_OUTPUT
echo "IS_RELEASE_COMMIT=1" >> $GITHUB_ENV
else
echo "This commit will NOT trigger a release."
if [ -z "$STRING" ]; then
echo "IS_RELEASE_COMMIT=1" >> $GITHUB_OUTPUT
echo "IS_RELEASE_COMMIT=1" >> $GITHUB_ENV
else
echo "This commit will NOT trigger a release."
echo "IS_RELEASE_COMMIT=0" >> $GITHUB_OUTPUT
echo "IS_RELEASE_COMMIT=0" >> $GITHUB_ENV
fi
echo "IS_RELEASE_COMMIT=0" >> $GITHUB_OUTPUT
echo "IS_RELEASE_COMMIT=0" >> $GITHUB_ENV
fi
- name: Install dependencies
run: npm ci -f
run: yarn

- name: Validate Markdown links
run: npm run check-links
run: yarn check-links

- name: Validate package.json
run: npm run validate-package-json
run: yarn validate-package-json

- name: Run ESLint
if: env.IS_RELEASE_COMMIT == '1'
run: |
npm run lint
yarn lint
- name: Build source code
if: env.IS_RELEASE_COMMIT == '1'
run: |
npm run build
yarn build
- name: Run test suites
if: env.IS_RELEASE_COMMIT == '1'
run: |
npm run test
yarn test
release:
if: needs.test.outputs.IS_RELEASE_COMMIT == '1'
permissions:
Expand Down Expand Up @@ -89,6 +88,7 @@ jobs:
publish-npm:
needs: release
runs-on: ubuntu-latest
environment: npm-registry
steps:
- name: Checkout code
uses: actions/checkout@v3
Expand All @@ -108,6 +108,7 @@ jobs:
run: yarn publish --access public
publish-gpr:
needs: release
environment: github-packages
permissions:
packages: write
runs-on: ubuntu-latest
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/pr-build-failed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ jobs:
Don't worry, it'll run again if you commit any changes to this PR.
- name: Label PR as "CI failed"
uses: actions/labeler@v4
with:
with:
sync-label: true
repo-token: ${{ secrets.GITHUB_TOKEN }}

2 changes: 1 addition & 1 deletion .github/workflows/pr-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ jobs:

- name: Checkout main
if: failure()
run: git clone https://github.com/${{ github.repository }} main/
run: git clone https://github.com/${{ github.repository }} main/
- name: Report build failed (if any)
if: failure()
uses: ./main/.github/workflows/pr-build-failed.yml
Expand Down
4 changes: 4 additions & 0 deletions .markdownlint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"MD013": false,
"MD010": false
}
6 changes: 6 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.*ignore
node_modules
LICENSE
coverage
yarn.lock
cjs
10 changes: 5 additions & 5 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"singleQuote": true,
"useTabs": true,
"trailingComma": "none",
"semi": true
}
"singleQuote": true,
"useTabs": true,
"trailingComma": "none",
"semi": true
}
7 changes: 2 additions & 5 deletions .remarkrc.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
{
"plugins": [
"gfm",
"validate-links"
]
}
"plugins": ["validate-links"]
}
23 changes: 8 additions & 15 deletions .vscode/new jest test.code-snippets
Original file line number Diff line number Diff line change
@@ -1,28 +1,21 @@
{
// Place your área de trabajo de equal-lib snippets here. Each snippet is defined under a snippet name and has a scope, prefix, body and
// description. Add comma separated ids of the languages where the snippet is applicable in the scope field. If scope
// is left empty or omitted, the snippet gets applied to all languages. The prefix is what is
// used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders.
// Place your área de trabajo de equal-lib snippets here. Each snippet is defined under a snippet name and has a scope, prefix, body and
// description. Add comma separated ids of the languages where the snippet is applicable in the scope field. If scope
// is left empty or omitted, the snippet gets applied to all languages. The prefix is what is
// used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders.
// Placeholders with the same ids are connected.
// Example:
"new test case": {
"scope": "javascript,typescript",
"prefix": "test case",
"body": [
"test('$1', () => {",
"\t$0",
"});"
],
"body": ["test('$1', () => {", "\t$0", "});"],
"description": "New Jest test"
},
"expect .toBe": {
"scope": "javascript,typescript",
"prefix": "expect toBe",
"body": [
"expect($1)",
"\t.toBe($0);"
],
"body": ["expect($1)", "\t.toBe($0);"],
"description": "New Jest test"
}
}
}
9 changes: 8 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
## Version 2.0.0 (MAJOR VERSION; BREAKING CHANGES!)

- **DELETED `assertType`.**
- **Replaced `assertOneOf`'s `shallow` parameter with `comparator` to remove reliance on `@santi100/equal-lib`.**
- **Replaced `assertOneOf`'s `shallow` parameter with `comparator` to remove reliance on `@santi100/equal-lib`.**
- Modified module system to use `export =` for all individual module files, whilst keeping compatibility.

## Version 2.0.1
Expand All @@ -27,3 +27,10 @@
## Version 2.0.2

- Fixed circular dependency bug with `assertTypeOf` and `assertOneOf`.

## Version 2.0.3

- Added `assertArrayTypes`.
- Added `assertDifferent`.
- Added `assertEqual`.
- Added `assertOneOfTypes`.
33 changes: 17 additions & 16 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,30 +5,30 @@
In the interest of fostering an open and welcoming environment, as
the maintainer, I pledge to make participation in my project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, level of experience, education,
socio-economic status, nationality, personal appearance, race,
size, disability, ethnicity, level of experience, education,
socio-economic status, nationality, personal appearance, race,
or religion.

## My Standards

Examples of behavior that contributes to creating a positive environment
include:

* Using welcoming language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
- Using welcoming language
- Being respectful of differing viewpoints and experiences
- Gracefully accepting constructive criticism
- Focusing on what is best for the community
- Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

* The use of sexualized or foul language or imagery and unwelcome sexual attention or
- The use of sexualized or foul language or imagery and unwelcome sexual attention or
advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic
- Trolling, insulting/derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or electronic
address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a
- Other conduct which could reasonably be considered inappropriate in a
professional setting

## My Responsibilities
Expand Down Expand Up @@ -58,6 +58,7 @@ Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting me at <[email protected]>. All complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. I will maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.

## Enforcement Guidelines

I will follow these Community Impact Guidelines in determining
Expand Down Expand Up @@ -98,7 +99,7 @@ Violating these terms may lead to a permanent ban.
### 4. Permanent Ban

**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.

**Consequence**: A permanent ban from any sort of public interaction within
Expand All @@ -110,12 +111,12 @@ This Code of Conduct is adapted from the [Contributor Covenant][homepage],
version 2.0, available at
<https://www.contributor-covenant.org/version/2/0/code_of_conduct.html>.

Community Impact Guidelines were inspired by
Community Impact Guidelines were inspired by
[Mozilla's code of conduct enforcement ladder][Mozilla CoC].

For answers to common questions about this code of conduct, see the FAQ at
<https://www.contributor-covenant.org/faq>. Translations are available
<https://www.contributor-covenant.org/faq>. Translations are available
at <https://www.contributor-covenant.org/translations>.

[homepage]: https://www.contributor-covenant.org
[Mozilla CoC]: https://github.com/mozilla/diversity
[Mozilla CoC]: https://github.com/mozilla/diversity
7 changes: 4 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@

## How to contribute

You can [file an issue](https://github.com/santi100a/equal-lib/issues)
or a [pull request](https://github.com/santi100a/equal-lib/pulls).
You can [file an issue](https://github.com/santi100a/equal-lib/issues)
or a [pull request](https://github.com/santi100a/equal-lib/pulls).
You can also [start a discussion](https://github.com/santi100a/equal-lib/discussions).

## Contribution rules
You must comply with the [Code of Conduct](CODE_OF_CONDUCT.md) when doing contributions.

You must comply with the [Code of Conduct](CODE_OF_CONDUCT.md) when doing contributions.
Loading

0 comments on commit 757cd5c

Please sign in to comment.