Skip to content

Commit

Permalink
chore: initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
helmturner committed Aug 19, 2023
0 parents commit f4c6bb2
Show file tree
Hide file tree
Showing 19 changed files with 2,488 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/version.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: version-package

on:
push:
branches:
- stage

jobs:
version:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- name: checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- run: git config --global user.email "[email protected]"
- run: git config --global user.name "Alec Helmturner"
- run: npm run version
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27 changes: 27 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: CI
on:
push:
branches:
- "**"
- "!main"
pull_request:
branches:
- "**"

concurrency: ${{ github.workflow }}-${{ github.ref }}

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node: [ 14, 16, 18, 20 ]
name: Node ${{ matrix.node }} build test
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
cache: "npm"
- run: npm install npm@latest -g
- run: npm run ci
37 changes: 37 additions & 0 deletions .github/workflows/release-please.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: release-please
on:
push:
branches:
- main

concurrency: ${{ github.workflow }}-${{ github.ref }}

jobs:
release-please:
permissions:
contents: write # to create release commit (google-github-actions/release-please-action)
pull-requests: write # to create release PR (google-github-actions/release-please-action)
runs-on: ubuntu-latest
name: Release, Please!
steps:
- name: Create release PR
uses: google-github-actions/release-please-action@v3
id: release
with:
command: manifest
release-type: "node"
- uses: actions/checkout@v3
if: ${{ steps.release.outputs.release_created }}
- uses: actions/setup-node@v3
with:
node-version: 18.x
cache: "npm"
if: ${{ steps.release.outputs.release_created }}
- name: Publish to NPM
run: |
npm install npm@latest -g
npm run release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
if: ${{ steps.release.outputs.release_created }}
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
node_modules
.DS_Store
dist/
coverage/
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
//registry.npmjs.org/:_authToken=${NPM_TOKEN}
4 changes: 4 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
node_modules
.vscode
package-lock.json
package.json
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"typescript.tsdk": "node_modules/typescript/lib",
}
Empty file added CHANGELOG.md
Empty file.
5 changes: 5 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
© AlecVision, LLC

Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.

THE SOFTWARE IS PROVIDED “AS IS” AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
101 changes: 101 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
{
"name": "@alldogs/hotenv",
"version": "0.0.0",
"author": "Alec Helmturner",
"license": "ISC",
"description": "The hottest env loader for Tamagui monorepos",
"engineStrict": true,
"engines": {
"node": ">=18.0.0"
},
"scripts": {
"dev": "vitest --coverage --ui",
"test": "vitest run --coverage && vitest typecheck --run",
"build": "tsup",
"ci": "npm ci && npm run test && npm run build",
"release": "npm run ci && npm publish --access=public",
"clean": "rm -rf dist && rm -rf coverage && rm -rf node_modules"
},
"main": "dist/index.js",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"files": [
"dist/*"
],
"bin": {
"hotenv": "./dist/index.js"
},
"exports": {
".": {
"import": "./dist/index.js",
"require": "./dist/index.cjs",
"types": "./dist/index.d.ts"
}
},
"repository": {
"type": "git",
"url": "https://github.com/alecvision/hotenv.git"
},
"bugs": {
"url": "https://github.com/alecvision/hotenv/issues"
},
"keywords": [
"hotenv",
"dotenv",
"t3-env",
"env",
"tamagui",
"monorepo",
"nextjs",
"expo"
],
"prettier": {
"semi": true,
"trailingComma": "none",
"arrowParens": "avoid",
"tabWidth": 2
},
"tsup": {
"banner": {
"js": "#!/usr/bin/env node\n"
},
"minify": true,
"minifyIdentifiers": true,
"minifySyntax": true,
"minifyWhitespace": true,
"skipNodeModulesBundle": true,
"treeshake": true,
"clean": true,
"dts": true,
"sourcemap": true,
"globalName": "hotenv",
"noExternal": [
"commander"
],
"platform": "node",
"target": "node18",
"tsconfig": "tsconfig.json",
"define": {
"import.meta.vitest": "undefined"
},
"entry": [
"./src/index.ts"
],
"outDir": "./dist",
"format": [
"esm",
"cjs"
]
},
"devDependencies": {
"@commander-js/extra-typings": "^11.0.0",
"@vitest/coverage-v8": "^0.34.2",
"prettier": "^3.0.2",
"tsup": "^7.2.0",
"typescript": "^5.1.6",
"vitest": "^0.34.2"
},
"dependencies": {
"commander": "^11.0.0"
}
}
Loading

0 comments on commit f4c6bb2

Please sign in to comment.