Skip to content

Commit

Permalink
prepare v2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ful1e5 committed Aug 16, 2022
1 parent 84d572c commit 3690217
Show file tree
Hide file tree
Showing 10 changed files with 96 additions and 64 deletions.
15 changes: 10 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: CI
name: ci

on:
push:
Expand All @@ -20,6 +20,13 @@ jobs:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ["3.7", "3.8", "3.9", "3.10"]
include:
- os: ubuntu-latest
path: ~/.cache/pip
- os: macos-latest
path: ~/Library/Caches/pip
- os: windows-latest
path: ~\AppData\Local\pip\Cache

steps:
- uses: actions/checkout@v2
Expand All @@ -30,12 +37,10 @@ jobs:

- name: Caching pip packages
uses: actions/cache@v2
id: pip-cache # use this to check for `cache-hit` (`steps.pip-cache.outputs.cache-hit != 'true'`)
with:
path: ~/.cache/pip
path: ${{ matrix.path }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }}
restore-keys: |
${{ runner.os }}-pip-
restore-keys: ${{ runner.os }}-pip-

- name: Install pip dependencies
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Publish
name: publish

on:
release:
Expand All @@ -24,7 +24,7 @@ jobs:
restore-keys: |
${{ runner.os }}-pip-
- name: Install pip dependencies
- name: Installing pip dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt
Expand Down
52 changes: 24 additions & 28 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,44 +7,39 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [unreleased]

### Added

-

### Changed
## [v2.0.0] - 16 August 2022

-
> **Warning**
> I removed all functionalities and modules from older versions in `v2.0.0`.
## [v2.0.0-beta.2] - 09 Jul 2022

### Changed

- :warning: Documentation moved to [wiki](https://github.com/ful1e5/clickgen/wiki)
- ctgen (cli): fixed platform assignment type in '-p/--platform' argument
- windows-writer: fixed slow animation in `.ani` cursors (60jifs(1000ms) -> 2 jifs(33ms))

## [v2.0.0-beta.1] - 27 Jun 2022

- **:warning: Breaking change**: removed all functionalities and modules from older versions in [v2.0.0].
- **Deprecated** Docker Image support due to cross-platform compatibility.
> **Warning**
> Docker Image support deprecated due to cross-platform compatibility.
### Added

- Building logs added in `ctgen`
- add: python 3.7 support
- add: **Windows** and **macOS** support fixed #24
- init: `cursor`, `configparser`, `packer`, `parser` and `writer` module
- 'Twitter' and 'Download' links added on PYPI page
- Cursor CLI: `clickgen -h`
- Theme CLI: `ctgen -h`
- Added cursor generator cli: `clickgen -h`
- Added cursor theme generator cli: `ctgen -h` (supports config file)
- Uninstall script added in Windows cursors theme.

### Changed

- Changed docs theme to 'furo'
- `KeyNotFound` Exception fixed while reading cursor configuration in `configparser` module
- ctgen (cli): fixed platform assignment type in '-p/--platform' argument
- windows-writer: fixed slow animation in `.ani` cursors (60jifs(1000ms) -> 2 jifs(33ms))
- chore: updated template variables inside `packer.windows`
- make: install all dependencies with `make install_deps` command
- chore: directory renamed `examples` -> `samples`

## [v1.2.0] - 26 Mar 2022
## [v2.0.0-beta.2] - 09 July 2022

## [v2.0.0-beta.1] - 27 June 2022

## [v1.2.0] - 26 March 2022

### Added

Expand Down Expand Up @@ -96,7 +91,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- make-stubgen: generate type interface(.pyi) files without `MODULES` variable
- refactor: `scripts` -> `src/clickgen/scripts`

## [v1.1.9] - 22 Mar 2021
## [v1.1.9] - 22 March 2021

### Added

Expand All @@ -115,7 +110,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Fixed #23 packaging issue of `XPackager`
- Fixed #22 Inside `util.PNGProvider`

## [v1.1.8] - 24 Jan 2021
## [v1.1.8] - 24 January 2021

### Added

Expand All @@ -135,7 +130,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- GitHub workflow with `matrix`
- fixed #12

## [v1.1.7] - 5 Oct 2020
## [v1.1.7] - 5 October 2020

### Added

Expand All @@ -147,7 +142,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

- skip `Pillow` is already installed

## [v1.1.6] - 24 Sept 2020
## [v1.1.6] - 24 September 2020

### Changed

Expand Down Expand Up @@ -203,7 +198,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed

- Windows cursors extension `null` to `.ani` or `.cur` in linker module.
- Restructure **test** 🧪
- Restructure **test**
- Logo **Alignment fix** in `README.md`
- CI Pipeline
- GitHub workflow name changed
Expand All @@ -221,7 +216,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- auto-generated **symlinks** based on input configs
- `.tar` archive & `directory` as out **package**.

[unreleased]: https://github.com/ful1e5/clickgen/compare/v2.0.0-beta.2...main
[unreleased]: https://github.com/ful1e5/clickgen/compare/v2.0.0...main
[v2.0.0]: https://github.com/ful1e5/clickgen/compare/v2.0.0...v2.0.0-beta.2
[v2.0.0-beta.2]: https://github.com/ful1e5/clickgen/compare/v2.0.0-beta.2...v2.0.0-beta.1
[v2.0.0-beta.1]: https://github.com/ful1e5/clickgen/compare/v2.0.0-beta.1...v1.1.9
[v1.2.0]: https://github.com/ful1e5/clickgen/compare/v1.1.9...v1.2.0
Expand Down
28 changes: 20 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,25 @@
# Clickgen

[![CI](https://github.com/ful1e5/clickgen/actions/workflows/ci.yml/badge.svg)](https://github.com/ful1e5/clickgen/actions/workflows/ci.yml)
[![Docs](https://readthedocs.org/projects/clickgen/badge/?version=latest)](https://clickgen.readthedocs.io/en/latest/)
[![Code Coverage](https://codecov.io/gh/ful1e5/clickgen/branch/main/graph/badge.svg)](https://codecov.io/gh/ful1e5/clickgen)
[![ci](https://github.com/ful1e5/clickgen/actions/workflows/ci.yml/badge.svg)](https://github.com/ful1e5/clickgen/actions/workflows/ci.yml)
[![code coverage](https://codecov.io/gh/ful1e5/clickgen/branch/main/graph/badge.svg)](https://codecov.io/gh/ful1e5/clickgen)

**Clickgen** is cross-platform python library for building **X11** and **Windows** Cursors.
Clickgen's core functionality is heavily inspired by **[quantum5/win2xcur](https://github.com/quantum5/win2xcur)**
from `clickgen<=v2.0.0`.
from `clickgen v2.0.0` and onwards.

##### Become Sponsor

This library is funded by the community. I appreciate all these wonderful people who patronize and sponsoring me.

Visit the [GitHub Sponsor](https://github.com/sponsors/ful1e5) page to become a partner.
DM me on [Twitter](https://twitter.com/ful1e5) if your company would like to sponsor this library,
I will gladly look into it and embed your logo in the README.

##### Sponsors

<!-- Add your name and avatar here with the Pull Request in case I missed it. -->

Be you first.

## Notices

Expand All @@ -25,8 +38,9 @@ from `clickgen<=v2.0.0`.
pip3 install clickgen
```

:warning: Distributions' packages are not affiliated with clickgen developers.
If you encounter any issues with the incorrect installation, you should contact the package maintainer first.
> **Note**
> Distributions' packages are not affiliated with clickgen developers.
> If you encounter any issues with the incorrect installation, you should contact the package maintainer first.
### Arch Linux

Expand All @@ -53,8 +67,6 @@ clickgen samples/pngs/wait-001.png samples/pngs/wait-001.png -d 3 -x 10 -y 10 -s

#### Windows Formats (.cur and .ani)

**WORK IN PROGRESS!**

To build [ponter.png](https://github.com/ful1e5/clickgen/blob/main/samples/pngs/pointer.png)
file to Windows Format (`.cur`):

Expand Down
2 changes: 1 addition & 1 deletion requirements.dev.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
wheel>=0.37.1
wheel>=0.37.1
flake8>=4.0.1
tox>=3.25.0
pytest>=7.1.2
Expand Down
14 changes: 7 additions & 7 deletions samples/sample.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
[theme]
name = "Sample"
comment = "This is sample cursor theme"
website = "https://www.example.com/"
name = 'Sample'
comment = 'This is sample cursor theme'
website = 'https://www.example.com/'

[config]
bitmaps_dir = "pngs"
out_dir = "out"
platforms = ['x11','windows']
bitmaps_dir = 'pngs'
out_dir = 'out'
platforms = ['x11', 'windows']
x11_sizes = [21, 24, 28, 32, 40, 48, 56, 64, 72, 80, 88, 96]
win_size = 32


[cursors]

[cursors.fallback_settings]
x_hotspot = 100
y_hotspot = 100
Expand Down
4 changes: 2 additions & 2 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@ keywords = cursor, xcursor, windows, linux
project_urls =
Source = https://github.com/ful1e5/clickgen
Download = https://pypi.org/project/clickgen/#files
Documentation = https://clickgen.readthedocs.io/en/latest/
Bug Tracker = https://github.com/ful1e5/clickgen/issues
Changelog = https://github.com/ful1e5/clickgen/blob/main/CHANGELOG.md
Funding = https://github.com/sponsors/ful1e5
Twitter = https://twitter.com/ful1e5
classifiers =
Development Status :: 4 - Beta
Development Status :: 5 - Production/Stable
License :: OSI Approved :: MIT License
Programming Language :: C
Programming Language :: Python :: 3
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Programming Language :: Python :: Implementation :: CPython
Topic :: Multimedia :: Graphics
Topic :: System :: Operating System
Expand Down
2 changes: 1 addition & 1 deletion src/clickgen/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-

__version__ = "2.0.0.beta2"
__version__ = "2.0.0"
4 changes: 2 additions & 2 deletions src/clickgen/configparser.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def get_value_with_fallback(key: str, deflt: T) -> T:
# Because all cursors don't have windows configuration
win_cursor: Union[bytes, None] = None
win_cursor_name: Union[str, None] = None
if v["win_name"]:
if "win_name" in v:
win_blob = open_blob(blobs, hotspot, [config.win_size], win_delay)
ext, win_cursor = to_win(win_blob.frames)
win_cursor_name = v["win_name"] + ext
Expand All @@ -101,7 +101,7 @@ def get_value_with_fallback(key: str, deflt: T) -> T:
CursorSection(
x11_cursor=x11_cursor,
x11_cursor_name=v["x11_name"],
x11_symlinks=v["x11_symlinks"],
x11_symlinks=v.get("x11_symlinks", []),
win_cursor=win_cursor,
win_cursor_name=win_cursor_name,
)
Expand Down
Loading

0 comments on commit 3690217

Please sign in to comment.