Skip to content

Commit

Permalink
Add Linux package and fix release
Browse files Browse the repository at this point in the history
* Compile using glibc 2.17 to get compatibility with lot of GNU/Linux distros
* fix release actions
  • Loading branch information
ahmet2mir committed Oct 20, 2020
1 parent a301c9b commit 1563cc6
Show file tree
Hide file tree
Showing 5 changed files with 48 additions and 49 deletions.
50 changes: 8 additions & 42 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,29 +6,9 @@ on:
- 'v*'

jobs:
create_release:
name: Create release
runs-on: ubuntu-latest
outputs:
id: ${{ steps.draft_release.outputs.id }}
html_url: ${{ steps.draft_release.outputs.html_url }}
upload_url: ${{ steps.draft_release.outputs.upload_url }}
steps:
- name: Create release
id: draft_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: true
prerelease: false

assets:
name: Release packages
runs-on: ${{ matrix.os }}
needs: create_release
strategy:
fail-fast: false
matrix:
Expand All @@ -39,23 +19,21 @@ jobs:
- name: Check out src from Git
uses: actions/checkout@v2

- name: Get history and tags for SCM versioning to work
run: |
git fetch --prune --unshallow
git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- name: Set up Python 3.6
uses: actions/setup-python@v1
if: matrix.os == 'macos-latest'
with:
python-version: 3.6

# Lower version of glibc is always compatible with greater version
# So the binary will we runnable on probably all linux stable/LTS distros
# https://pyinstaller.readthedocs.io/en/stable/usage.html#making-gnu-linux-apps-forward-compatible
# So I use a custom python image with pyinstaller on centos7 (glibc 2.17)
- name: Init environment and build package for GNU/Linux
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get install -y ruby ruby-dev rubygems build-essential
gem install --user --no-document fpm
export PATH=/home/runner/.gem/ruby/2.5.0/bin:$PATH
make init archive-linux package-rpm package-deb
uses: ahmet2mir/docker-python@master
with:
make_args: init archive-linux package-rpm package-deb

- name: Init environment and build package for OSX
if: matrix.os == 'macos-latest'
Expand All @@ -80,15 +58,3 @@ jobs:
if: matrix.os == 'ubuntu-latest'
with:
password: ${{ secrets.GH_ACTIONS_WILD }}

finish_release:
name: Finish release
runs-on: ubuntu-latest
needs: [assets, create_release]
steps:
- name: Unset draft
uses: ahmet2mir/eregon-publish-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
release_id: ${{ needs.create_release.outputs.id }}
3 changes: 0 additions & 3 deletions Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,3 @@ jq = "*"
pyhcl = "*"
click = "*"
pygments = "*"

[requires]
python_version = "3.6"
36 changes: 33 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@


# wildq - Command-line TOML/JSON/INI/YAML/XML/HCL processor using jq c bindings

![GitHub](https://img.shields.io/github/license/ahmet2mir/wildq.svg)
Expand Down Expand Up @@ -31,12 +33,40 @@ brew install ahmet2mir/tap/wildq
brew install ahmet2mir/tap/wq
```

## Debian (no gpg signature)
## GNU/Linux Binary

Compiled using glibc 2.17, it should work on lot of stable/LTS distros.

```
mkdir -p ~/bin/
curl -sL https://github.com/ahmet2mir/wildq/releases/download/v1.1.5/wildq-1.1.5-linux-x86_64.tar.gz -o wildq-1.1.5-linux-x86_64.tar.gz
tar xvfz wildq-1.1.5-linux-x86_64.tar.gz -C ~/bin
export PATH="~/bin:$PATH"
wq --help
wildq --help
```
wget https://github.com/ahmet2mir/wildq/releases/download/v1.1.4/wildq_1.1.4-1_amd64.deb
dpkg -i wildq_1.1.4-1_amd64.deb

## Debian (no gpg signature) >= 10

```
curl -sL https://github.com/ahmet2mir/wildq/releases/download/v1.1.5/wildq_1.1.5-1_amd64.deb -o wildq_1.1.5-1_amd64.deb
sudo dpkg -i wildq_1.1.5-1_amd64.deb
wq --help
wildq --help
```

## Centos (no gpg singature) >= 7

```
curl -sL https://github.com/ahmet2mir/wildq/releases/download/v1.1.5/wildq-1.1.5-1.x86_64.rpm -o wildq-1.1.5-1.x86_64.rpm
sudo yum install -y ./wildq-1.1.5-1.x86_64.rpm
wq --help
wildq --help
```


## Windows

Expand Down
6 changes: 6 additions & 0 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
Changelog
=========

v1.1.5 - 20/10/2020
===================

- Compile using glibc 2.17 to get compatibility with lot of GNU/Linux distros
- fix release actions

v1.1.4 - 12/10/2020
===================

Expand Down
2 changes: 1 addition & 1 deletion wildq/_wildq_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version = "1.1.4"
version = "1.1.5"

0 comments on commit 1563cc6

Please sign in to comment.