Skip to content

Commit fd74854

Browse files
authored
Merge pull request #2 from SOSETH/fix-packaging
Fixup packaging
2 parents e8413b1 + 216cc69 commit fd74854

File tree

13 files changed

+41
-5
lines changed

13 files changed

+41
-5
lines changed

.github/workflows/python-ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Python package
1+
name: Python lint
22

33
on: [push]
44

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Python package
2+
permissions:
3+
contents: write
4+
5+
on:
6+
push:
7+
tags:
8+
- "v*"
9+
10+
jobs:
11+
build-release:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v3
15+
- name: Set up Python
16+
uses: actions/setup-python@v4
17+
with:
18+
python-version: '3.10'
19+
- name: Build release
20+
run: |
21+
python -m pip install --upgrade pip
22+
pip install --upgrade build setuptools
23+
python -m setup
24+
- name: Release
25+
uses: softprops/action-gh-release@v1
26+
with:
27+
files: |
28+
dist/gitsync*

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ venv
44
dist
55
config.yaml
66
gitsync.egg-info
7+
*.pyc

pyproject.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,6 @@ dependencies = [
1313
"PyGithub"
1414
]
1515
readme = 'README.md'
16+
17+
[project.scripts]
18+
gitsync = "sync:do_sync"

src/__init__.py

Whitespace-only changes.
File renamed without changes.
File renamed without changes.

lib/github.py renamed to src/lib/github.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from typing import List, Set
22

3-
from lib.api import GitProvider, GitProject
3+
from src.lib.api import GitProvider, GitProject
44
from github import Github, Repository
55
from urllib.parse import urlparse
66
from datetime import datetime, timedelta

lib/gitlab.py renamed to src/lib/gitlab.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
from gitlab.v4.objects import Project
33
from urllib.parse import urlparse
44
from typing import List, Set
5-
from lib.api import GitProvider, GitProject
5+
from src.lib.api import GitProvider, GitProject
66
from datetime import datetime, timedelta, timezone
77

88

File renamed without changes.

0 commit comments

Comments
 (0)