Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
61 changes: 61 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: CI / CD - Morse Code

on:
pull_request:
branches: [pipfile-experiment]
push:
tags: ["v*"]
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 5
strategy:
matrix:
python-version: ["3.10", "3.11"]

steps:
- uses: actions/checkout@v4

- name: Install Python and Pipenv
uses: kojoru/prepare-pipenv@v1
with:
python-version: ${{ matrix.python-version }}


- name: Turn on 'editable' mode
run: |
pipenv install -e .

- name: Run pytest
run: |
pipenv install pytest
pipenv --venv
pipenv run python -m pytest

deliver:
if: github.event_name != 'pull_request'
needs: [build]
runs-on: ubuntu-latest
timeout-minutes: 5

steps:
- uses: actions/checkout@v4

- name: Install Python, pipenv and Pipfile packages
uses: kojoru/prepare-pipenv@v1
with:
python-version: "3.10"

- name: Build package
run: |
pipenv install build
pipenv run python -m build .

# publish to PyPI Test server
# - name: Publish to TestPyPI
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# password: ${{ secrets.TEST_PYPI_API_TOKEN }}
# repository-url: https://test.pypi.org/legacy/
13 changes: 13 additions & 0 deletions Pipfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"

[packages]
pytest = "*"
morse_code = {file = ".", editable = true}

[dev-packages]

[requires]
python_version = "3.10"
74 changes: 74 additions & 0 deletions Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Empty file added examples/demo.py
Empty file.
31 changes: 31 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
[build-system]
requires = ["setuptools>=68", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "morse_code"
version = "0.1.0"
description = "A Python package for encoding and decoding Morse code."
readme = "README.md"
requires-python = ">=3.10"
license = { file = "LICENSE" }
authors = [{ name = "Team Lumen" }]
keywords = ["python", "morse code", "encoder", "decoder"]
classifiers = [
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent"
]

[project.urls]
Homepage = "https://github.com/swe-students-fall2025/3-python-package-team_lumen"
Issues = "https://github.com/swe-students-fall2025/3-python-package-team_lumen/issues"

[tool.setuptools]
package-dir = {"" = "src"}

[tool.setuptools.packages.find]
where = ["src"]

[project.scripts]
morse_code = "morse_code.core:cli"
Empty file added src/morse_code/__init__.py
Empty file.
Empty file added tests/test_decode.py
Empty file.
Empty file added tests/test_encode.py
Empty file.
Loading