File: fabfile.py

package info (click to toggle)
pychromecast 2.4.0-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 332 kB
  • sloc: python: 1,751; makefile: 6; sh: 3
file content (25 lines) | stat: -rw-r--r-- 523 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import os
from fabric.decorators import task
from fabric.operations import local


@task
def build():
    """
    Builds the distribution files
    """
    if not os.path.exists("build"):
        os.mkdir("build")
    local("date >> build/log")
    local("python setup.py sdist >> build/log")
    local("python setup.py bdist_wheel >> build/log")


@task
def release():
    """
    Uploads files to PyPi to create a new release.

    Note: Requires that files have been built first
    """
    local("twine upload dist/*")