Skip to content

Commit

Permalink
feat: initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
marinofranz committed Jul 18, 2024
0 parents commit 7538bf9
Show file tree
Hide file tree
Showing 19 changed files with 2,053 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
36 changes: 36 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Publish package

on:
push:
branches: ["main"]

jobs:
publish:
name: "Publish"
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 8
run_install: false

- name: Setup Node 20.x
uses: actions/setup-node@v4
with:
node-version: "20.x"
cache: pnpm
registry-url: https://registry.npmjs.org

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Publish to registry
shell: bash
run: pnpm publish --access public --no-git-checks
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules/
dist/
4 changes: 4 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"semi": true,
"singleQuote": false
}
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024 Relatio LLC

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# @relatiohq/utils
> [Website](https://relatio.cc)
@relatiohq/utils is a package of utility functions used by Relatio products

## How to install
```sh
npm i @relatiohq/utils
```

```sh
yarn add @relatiohq/utils
```

```sh
pnpm add @relatiohq/utils
```
12 changes: 12 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import globals from "globals";
import pluginJs from "@eslint/js";
import tseslint from "typescript-eslint";
import eslintConfigPrettier from "eslint-config-prettier";

export default [
{ files: ["**/*.{js,mjs,cjs,ts}"] },
{ languageOptions: { globals: { ...globals.browser, ...globals.node } } },
pluginJs.configs.recommended,
...tseslint.configs.recommended,
eslintConfigPrettier,
];
32 changes: 32 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"name": "utils",
"version": "1.0.0",
"description": "@relatiohq/utils is a package of utility functions used by Relatio products",
"author": "@relatiohq",
"license": "MIT",
"main": "dist",
"typings": "dist",
"repository": {
"type": "git",
"url": "git+https://github.com/relatiocc/utils.git"
},
"scripts": {
"prepublishOnly": "pnpm lint && pnpm test && pnpm build",
"build": "tsc",
"test": "vitest run",
"lint": "eslint",
"format": "pnpm exec prettier . --write"
},
"devDependencies": {
"@eslint/js": "^9.7.0",
"@types/node": "^20.14.11",
"eslint": "9.x",
"eslint-config-prettier": "^9.1.0",
"globals": "^15.8.0",
"prettier": "3.3.3",
"tslib": "^2.6.3",
"typescript": "^5.5.3",
"typescript-eslint": "^7.16.1",
"vitest": "^2.0.3"
}
}
Loading

0 comments on commit 7538bf9

Please sign in to comment.