Skip to content

Commit

Permalink
restructured for workflow optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
Spartanlasergun committed Jun 6, 2024
1 parent 991970a commit 2b2984f
Show file tree
Hide file tree
Showing 31 changed files with 60 additions and 240 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Publish Python Package

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.12'

- name: Install latest version of build
run: pip install --upgrade build

- name: Build package
run: python -m build

- name: Install twine
run: pip install --upgrade twine

- name: Publish package to TestPyPI
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.CALENDAR_WIDGET_TOKEN }}
run: twine upload --repository dist/* --skip-existing
Empty file removed .gitignore
Empty file.
1 change: 1 addition & 0 deletions calendar_widget/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from calendar_widget import Calendar
File renamed without changes.
Binary file removed dist/calendar_widget-1.0.0-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.0.tar.gz
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.1-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.1.tar.gz
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.2-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.2.tar.gz
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.3-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.3.tar.gz
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.4-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.4.tar.gz
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.5-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.5.tar.gz
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.6-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.6.tar.gz
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.7-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.7.tar.gz
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.8-py3-none-any.whl
Binary file not shown.
Binary file removed dist/calendar_widget-1.0.8.tar.gz
Binary file not shown.
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[build-system]
requires = ["setuptools>=61.0"]
build-backend = "setuptools.build_meta"
requires = ["hatchling"]
build-backend = "hatchling.build"

[project]
name = "calendar_widget"
Expand Down
202 changes: 0 additions & 202 deletions src/calendar_widget.egg-info/PKG-INFO

This file was deleted.

10 changes: 0 additions & 10 deletions src/calendar_widget.egg-info/SOURCES.txt

This file was deleted.

1 change: 0 additions & 1 deletion src/calendar_widget.egg-info/dependency_links.txt

This file was deleted.

1 change: 0 additions & 1 deletion src/calendar_widget.egg-info/top_level.txt

This file was deleted.

1 change: 0 additions & 1 deletion src/calendar_widget/__init__.py

This file was deleted.

Binary file not shown.
20 changes: 20 additions & 0 deletions tests/import_test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import tkinter
import calendar_widget

# define the main window into which the widget will be placed
root = tkinter.Tk()
root.geometry('600x600') # the geometry function defines the size of the tkinter window
# - in this case, we are using a window that is 600px by 600px

# create the calendar widget
Calendar = Calendar(root, # specify the tkinter window into which the widget will be placed
pos_x = 0, # set the x position of the calendar widget within the tkinter window
pos_y = 0, # set the y position of the calendar widget within the tkinter window
background = 'lightblue', # set the background of the calendar to light blue
)

# Note: images of the type 'png', 'gif', 'ppm', and 'pgm' can be set as the background.
# However, these images will not scale with the size of the calendar.

# remember to call your mainloop function so that the tkinter window is persistent
root.mainloop()
23 changes: 0 additions & 23 deletions tests/test.py

This file was deleted.

0 comments on commit 2b2984f

Please sign in to comment.