-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
v1.0.0 -- unminipy release and autopublish of MacOS executables
- Loading branch information
Showing
6 changed files
with
71 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: main | ||
|
||
on: | ||
push: | ||
tags: | ||
- 'v[0-9]+\.[0-9]+\.[0-9]+' | ||
|
||
jobs: | ||
build-and-release: | ||
permissions: write-all | ||
runs-on: macos-12 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Configure Python3 | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.11' | ||
cache: 'pip' | ||
|
||
- name: Install pyinstaller | ||
run: pip install pyinstaller && pip install -r requirements.txt | ||
|
||
- name: Bootstrap venv | ||
run: script/init.sh && source script/env-up.sh | ||
|
||
- name: Build latest release | ||
run: pyinstaller --onefile --paths unminipy-env/lib/python3.11/site-packages --hidden-import pyperclip -n unminipy unmini.py | ||
|
||
- name: Prep artifact | ||
run: chmod 777 dist/unminipy && cd dist && zip unminipy.zip unminipy && cd - | ||
|
||
- name: Test artifact | ||
run: dist/unminipy --clip | ||
|
||
- name: Release | ||
uses: ncipollo/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
allowUpdates: false | ||
artifacts: "dist/unminipy.zip" | ||
bodyFile: releases.md | ||
draft: false | ||
makeLatest: true | ||
name: Release ${{ github.ref_name }} | ||
prerelease: false | ||
removeArtifacts: true | ||
skipIfReleaseExists: true | ||
tag: ${{ github.ref_name }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,7 @@ __pycache__/ | |
# pyinstaller | ||
build/ | ||
dist/ | ||
*.tar.* | ||
|
||
# OS | ||
*.local | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# v1.0.0 | ||
unminipy v1: a simple executable that allows for converting minified JSON provided either thru the user's clipboard | ||
or a local file into an unminified format. | ||
|
||
- v1.0.0's executable in GH releases only works for MacOS | ||
- to use v1.0.0 on linux or windows, clone and follow the README.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#!/bin/sh | ||
pyinstaller --onefile --paths unminipy-env/lib/python3.11/site-packages --hidden-import pyperclip -n unminipy unmini.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
## ci/cd | ||
- workflow for building & publishing | ||
- pip install | ||
- pyinstaller | ||
- publish version to Github under repo releases | ||
- in main.yml, publish a version per each host: | ||
- linux | ||
- ~~macos~~ | ||
- windows | ||
|
||
## bin | ||
- make a `--save` arg that will save the unminified output to a file |