Skip to content

Commit

Permalink
Merge pull request #32 from sinamics/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
sinamics authored Apr 6, 2023
2 parents af3290f + a24867d commit ce641df
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 14 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/ci-tag-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: "Create new release tag"

on:
push:
tags:
- "v*"

jobs:
tagged-release:
name: "Tagged Release"
runs-on: "ubuntu-latest"

steps:
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: ${{ contains(github.ref, 'beta') || contains(github.ref, 'alfa') }}
files: |
LICENSE
README.md
22 changes: 12 additions & 10 deletions .github/workflows/ci-tag.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Build new docker image when a new tag is pushed, and generate changelog and release notes and use the tag as the release name.
# if the tag has beta or alfa in the name, set the release as a pre-release.

name: Push Tag build container
name: Build release image

on:
push:
Expand Down Expand Up @@ -62,12 +62,14 @@ jobs:
${{ secrets.DOCKER_USERNAME }}/${{ secrets.DOCKER_REPOSITORY }}:latest
${{ secrets.DOCKER_USERNAME }}/${{ secrets.DOCKER_REPOSITORY }}:${{ steps.extract_version.outputs.version_number }}
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: ${{ contains(github.ref, 'beta') || contains(github.ref, 'alfa') }}
automatic_release_tag: ${{ github.event.inputs.version || steps.previoustag.outputs.tag }}
title: ${{ steps.previoustag.outputs.tag }}
files: |
LICENSE
README.md
# - uses: "marvinpinto/action-automatic-releases@latest"
# with:
# repo_token: "${{ secrets.GITHUB_TOKEN }}"
# prerelease: ${{ contains(github.ref, 'beta') || contains(github.ref, 'alfa') }}
# files: |
# LICENSE
# README.md

# prerelease: ${{ contains(github.ref, 'beta') || contains(github.ref, 'alfa') }}
# automatic_release_tag: ${{ github.event.inputs.version || steps.previoustag.outputs.tag }}
# title: ${{ steps.previoustag.outputs.tag }}
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ services:
platform: "linux/amd64"
working_dir: /app
volumes:
- zerotier:/var/lib/zerotier-one
- zerotier:/var/lib/zerotier-one:ro
restart: unless-stopped
ports:
- 3000:3000
Expand Down
4 changes: 2 additions & 2 deletions src/components/elements/inputField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,9 @@ const InputField = ({
) : (
<dd className="mt-1 flex items-center gap-2 text-sm">
{placeholder ?? fields[0].placeholder}
{badge && (
{badge ? (
<div className={`badge badge-${badge.color}`}>{badge.text}</div>
)}
) : null}
</dd>
)}
</>
Expand Down
8 changes: 7 additions & 1 deletion src/utils/ztApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -184,9 +184,15 @@ export const network_create = async (
if (axios.isAxiosError(error)) {
const axiosError = error as AxiosError;
// eslint-disable-next-line no-console
console.error(axiosError.response?.statusText || "Unknown error");
console.error(`Axios error: ${axiosError.message}`);
// eslint-disable-next-line no-console
console.error(`Status code: ${axiosError.response?.status}`);
// eslint-disable-next-line no-console
console.error(`Status text: ${axiosError.response?.statusText}`);
throw axiosError;
}
// eslint-disable-next-line no-console
console.error(`Unknown error: ${error.message}`);
throw error;
}
};
Expand Down

0 comments on commit ce641df

Please sign in to comment.