Skip to content

Commit

Permalink
feat: First release
Browse files Browse the repository at this point in the history
  • Loading branch information
simenandre committed Dec 9, 2020
1 parent 552c5d4 commit 7321d5d
Show file tree
Hide file tree
Showing 337 changed files with 47,610 additions and 3 deletions.
Binary file added .DS_Store
Binary file not shown.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/**/*.js
25 changes: 25 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"env": {
"browser": false,
"es6": true,
"node": true
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"project": "tsconfig.json",
"sourceType": "module"
},
"plugins": [
"@typescript-eslint",
"jest"
],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:jest/recommended",
"prettier",
"prettier/@typescript-eslint"
],
"rules": {}
}
Binary file added .github/fiken-js-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
71 changes: 71 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
name: "CodeQL"

on:
push:
branches: [main]
pull_request:
# The branches below must be a subset of the branches above
branches: [main]
schedule:
- cron: '0 12 * * 0'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
# Override automatic language detection by changing the below list
# Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python']
language: ['javascript']
# Learn more...
# https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection

steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth: 2

# If this run was triggered by a pull request event, then checkout
# the head of the pull request instead of the merge commit.
- run: git checkout HEAD^2
if: ${{ github.event_name == 'pull_request' }}

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
32 changes: 32 additions & 0 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Build
on: [pull_request]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [12.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v1
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- run: yarn install
- run: yarn run lint
- run: yarn run build
46 changes: 46 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Release
on:
push:
branches:
- main

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [12.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v1
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- run: yarn install
- run: yarn run lint
- run: yarn run build
- name: Semantic Release
id: semantic
uses: cycjimmy/semantic-release-action@v2
with:
semantic_version: 17.0.7
extra_plugins: |
@semantic-release/[email protected]
@semantic-release/git
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
7 changes: 5 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,9 @@ typings/
# Next.js build output
.next

# Nuxt.js build / generate output
.nuxt
# Build files
dist
build

# Gatsby files
.cache/
Expand All @@ -102,3 +102,6 @@ dist

# TernJS port file
.tern-port

# OpenAPI stuff
openapi-generator-cli.jar
6 changes: 6 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"arrowParens": "avoid",
"singleQuote": true,
"trailingComma": "all",
"proseWrap": "always"
}
17 changes: 17 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
generate:
java -jar openapi-generator-cli.jar \
generate \
-i ./swagger.json \
-g typescript-fetch \
-o ./src/generated \
--additional-properties=supportsES6=true,useSingleRequestParameter=true,typescriptThreePlus=true

download_jars:
curl -o ./openapi-generator-cli.jar https://repo1.maven.org/maven2/org/openapitools/openapi-generator-cli/5.0.0-beta3/openapi-generator-cli-5.0.0-beta3.jar

download_swagger:
curl -o ./swagger.json https://api.fiken.no/api/v2/docs/swagger.yaml

.PHONY: download_swagger
.PHONE: download_jars
.PHONY: generate
59 changes: 58 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,58 @@
# fiken-js
![Fiken API Client][banner]

![Build & Deploy][build-badge]
[![Total alerts][lgtm-badge]][lgtm-alerts]
[![LGTM Grade][lgtm-grade]][lgtm-alerts]
[![Maintainability][codeclimate-badge]][codeclimate]
[![npm bundle size][bundle-size]][npm]

# Fiken API Client

Fiken-js is a Typescript/Javascript client that simplifies the use with [Fiken
API][fiken-api].

**Warning**: This package is currently under development. The maintainers of
this package is not currently using this in any production load. Please be
advised. That said, please use it, share experience and contribute!

## Quickstart

```shell
▶ yarn add fiken
```

## Documentation

Apart from this README, you can find details and examples of using the SDK in
the following places:

- [SDK Documentation][sdk-doc]
- [API Documentation][fiken-api]

## Contributing

Send bug reports, feature requests, and code contributions to this repository.
The project is maintained by Bjerk AS.

Contributions to this library is much appreciated. Please have a look at project
tab or issues for more information on current help-needed.

## Disclaimer

This project is not associated with Folio AS at all. The maintainer works with
their platform and have done so for many years. The Folio logo belongs to Folio
AS. We put it there only so people would know we are speaking of the Folio
accounting software, owned and provided by the Norwegian registered company
Folio.

[fiken-api]: https://api.fiken.no/api/v2/docs/
[sdk-doc]: ./docs/
[banner]: ./.github/fiken-js-logo.png
[npm]: https://www.npmjs.com/package/fiken
[build-badge]: https://img.shields.io/github/workflow/status/bjerkio/fiken-js/push
[codeclimate-badge]: https://img.shields.io/codeclimate/maintainability/bjerkio/fiken-js
[codeclimate]: https://codeclimate.com/github/bjerkio/fiken-js/maintainability
[lgtm-badge]: https://img.shields.io/lgtm/alerts/g/bjerkio/fiken-js.svg?logo=lgtm&logoWidth=18
[lgtm-alerts]: https://lgtm.com/projects/g/bjerkio/fiken-js/alerts/
[lgtm-grade]: https://img.shields.io/lgtm/grade/javascript/github/bjerkio/fiken-js
[bundle-size]: https://img.shields.io/bundlephobia/min/fiken
Loading

0 comments on commit 7321d5d

Please sign in to comment.