Skip to content

Commit

Permalink
updated readme and workflow file
Browse files Browse the repository at this point in the history
  • Loading branch information
zaaakher committed Sep 20, 2023
1 parent 2abf48f commit c860e4f
Show file tree
Hide file tree
Showing 6 changed files with 109 additions and 89 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/hajar-beta.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Hajar CI - @beta

env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
GH_TOKEN: ${{ secrets.GH_TOKEN }}
NPM_PUBLISH_TAG: beta # Specify the tag for publishing

on:
push:
branches: [main]

jobs:
publish-package:
if: ${{!contains(github.event.head_commit.message, 'skip_publish')}}

runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]

steps:
- uses: actions/checkout@v2

- name: Append -beta to package.json version
run: |
node -e "const fs = require('fs'); const packageJson = require('./package.json'); packageJson.version += '-beta'; fs.writeFileSync('./package.json', JSON.stringify(packageJson, null, 2));"
- uses: actions/setup-node@v2
with:
node-version: 16
registry-url: https://registry.npmjs.org/
always-auth: true

- name: Install dependencies
run: |
if [ -e 'package-lock.json' ]; then
npm ci
else
npm install
fi
- name: Build Library
run: npm run build --if-present
- name: Test & Lint
run: |
npm run test:coverage --if-present
npm run lint --if-present
- name: Publish to NPM @beta tag
run: npm publish --tag $NPM_PUBLISH_TAG
40 changes: 40 additions & 0 deletions .github/workflows/hajar-main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Hajar CI - @latest

env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
GH_TOKEN: ${{ secrets.GH_TOKEN }}

on:
release:
types:
- created

jobs:
publish-package:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
steps:
- uses: actions/checkout@v2

- name: Use Node.js v16
uses: actions/setup-node@v2
with:
node-version: 16
registry-url: https://registry.npmjs.org/
- name: Install dependencies
run: |
if [ -e 'package-lock.json' ]; then
npm ci
else
npm install
fi
- name: Build Library
run: npm run build --if-present
- name: Test & Lint
run: |
npm run test:coverage --if-present
npm run lint --if-present
- name: Publish to NPM main tag
run: npm publish
38 changes: 0 additions & 38 deletions .github/workflows/hajar-publish-push.yml

This file was deleted.

37 changes: 0 additions & 37 deletions .github/workflows/hajar-publish.yml

This file was deleted.

32 changes: 19 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,28 @@

# Hajar | حجر

[![NPM](https://img.shields.io/npm/v/@sikka/hajar.svg?style=flat&colorA=000000&colorB=000000)](https://www.npmjs.com/package/@sikka/hajar)
[![NPM](https://img.shields.io/npm/dt/@sikka/hajar.svg?style=flat&colorA=000000&colorB=000000)](https://www.npmjs.com/package/@sikka/hajar)
[![NPM](https://img.shields.io/npm/v/@sikka/hajar.svg?style=flat&colorA=000000&colorB=1082c3)](https://www.npmjs.com/package/@sikka/hajar)
[![NPM@beta](https://img.shields.io/npm/v/@sikka/hajar/beta.svg?style=flat&colorA=000000&colorB=ea7637)](https://www.npmjs.com/package/@sikka/hajar)
[![Hajar CI - @latest](https://github.com/sikka-software/Hajar/actions/workflows/hajar-main.yml/badge.svg)](https://github.com/sikka-software/Hawa/actions/workflows/hajar-main.yml)
[![Hajar CI - @beta](https://github.com/sikka-software/Hajar/actions/workflows/hajar-beta.yml/badge.svg)](https://github.com/sikka-software/Hajar/actions/workflows/hajar-beta.yml)

> Javascript/Typescript engine Saas/Paas applications
## Install

**Note:** `@beta` only points to pre-releases.
Use `@latest` for the latest stable release.

```bash
npm install @sikka/hajar
```

[documentation](https://zakher.gitbook.io/hajar/)

# Benefits

Many SaaS projects have the same foundation and architecture. Using a dynamic external library like Hajar will make it easier and faster to complete the internal functions of your SaaS project.



# Table of content

<!-- TABLE OF CONTENTS -->
Expand Down Expand Up @@ -54,8 +63,6 @@ Many SaaS projects have the same foundation and architecture. Using a dynamic ex

<br>



## Install

```bash
Expand All @@ -74,12 +81,12 @@ npm install --save @sikka/hajar

### Invoices

| <div style="width:220px">Function</div> | Discription |
|---|---|
| [CreateInvoice]() | This component is responsible for displaying Youtube videos that the developer preselects. |
| [placeholder]() | Fixed banner is the area in charge of displaying a banner that is fixated on the home page. |
| <div style="width:220px">Function</div> | Discription |
| --------------------------------------- | ------------------------------------------------------------------------------------------- |
| [CreateInvoice]() | This component is responsible for displaying Youtube videos that the developer preselects. |
| [placeholder]() | Fixed banner is the area in charge of displaying a banner that is fixated on the home page. |

<!--
<!--
This will be used to create an invoice with ready a ready template.
Arguments:
Expand Down Expand Up @@ -110,7 +117,7 @@ invoice_date: "01/11/2020"
invoice_currency: "SAR"
return: "base64" // default: create file in the root app in folder invoice and return boolean true or false
``` -->
<!--
<!--
### SendEmail()
Send an email to the user for billing, verification, password reset, or other reasons
Expand Down Expand Up @@ -174,7 +181,6 @@ arguments
### SetupPayment() -->


## Support

The team is always here to help you. Happen to face an issue? Want to report a bug? You can submit one here on Github using the [Issue Tracker](https://github.com/sikka-software/hajar/issues/new).
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@sikka/hajar",
"version": "1.1.5",
"version": "1.1.6",
"description": "Toolkit to create SaaS applications",
"author": "Sikka Software <[email protected]> (http://sikka.io)",
"license": "MIT",
Expand Down

0 comments on commit c860e4f

Please sign in to comment.