diff --git a/.github/workflows/publish_build.yml b/.github/workflows/publish_build.yml index 65e168b..9fdcd30 100644 --- a/.github/workflows/publish_build.yml +++ b/.github/workflows/publish_build.yml @@ -19,17 +19,10 @@ jobs: - name: Install Build Tools run: | python -m pip install build wheel - - name: Install OSM - run: | - pip install ovos-skills-manager~=0.0.10 - name: Remove alpha (declare stable) run: | VER=$(python setup.py --version) python scripts/remove_alpha.py - - name: Prepare Skillstore metadata - run: | - python scripts/prepare_skillstore.py - python scripts/release_skillstore.py - name: "Generate release changelog" uses: heinrichreimer/github-changelog-generator-action@v2.3 with: diff --git a/.github/workflows/publish_major.yml b/.github/workflows/publish_major.yml index 09121b4..87cee86 100644 --- a/.github/workflows/publish_major.yml +++ b/.github/workflows/publish_major.yml @@ -19,17 +19,10 @@ jobs: - name: Install Build Tools run: | python -m pip install build wheel - - name: Install OSM - run: | - pip install ovos-skills-manager~=0.0.10 - name: Remove alpha (declare stable) run: | VER=$(python setup.py --version) python scripts/remove_alpha.py - - name: Prepare Skillstore metadata - run: | - python scripts/prepare_skillstore.py - python scripts/release_skillstore.py - name: "Generate release changelog" uses: heinrichreimer/github-changelog-generator-action@v2.3 with: diff --git a/.github/workflows/publish_minor.yml b/.github/workflows/publish_minor.yml index fe98511..4e8b231 100644 --- a/.github/workflows/publish_minor.yml +++ b/.github/workflows/publish_minor.yml @@ -19,17 +19,10 @@ jobs: - name: Install Build Tools run: | python -m pip install build wheel - - name: Install OSM - run: | - pip install ovos-skills-manager~=0.0.10 - name: Remove alpha (declare stable) run: | VER=$(python setup.py --version) python scripts/remove_alpha.py - - name: Prepare Skillstore metadata - run: | - python scripts/prepare_skillstore.py - python scripts/release_skillstore.py - name: "Generate release changelog" uses: heinrichreimer/github-changelog-generator-action@v2.3 with: diff --git a/scripts/prepare_skillstore.py b/scripts/prepare_skillstore.py deleted file mode 100644 index 411734c..0000000 --- a/scripts/prepare_skillstore.py +++ /dev/null @@ -1,76 +0,0 @@ -from ovos_skills_manager import SkillEntry -from os.path import exists, join, dirname -from shutil import rmtree -import os -from os import makedirs -import json -from ovos_utils.bracket_expansion import expand_parentheses, expand_options - - -branch = "dev" -repo = "skill-ovos-date-time" -author = "OpenVoiceOS" - -url = f"https://github.com/{author}/{repo}@{branch}" - -skill = SkillEntry.from_github_url(url) -tmp_skills = "/tmp/osm_installed_skills" -skill_folder = f"{tmp_skills}/{skill.uuid}" - -base_dir = dirname(dirname(__file__)) -desktop_dir = join(base_dir, "res", "desktop") -android_ui = join(base_dir, "ui", "+android") -makedirs(desktop_dir, exist_ok=True) - -readme = join(base_dir, "README.md") -jsonf = join(desktop_dir, "skill.json") -desktopf = join(desktop_dir, f"{repo}.desktop") -skill_code = join(base_dir, "__init__.py") - -res_folder = join(base_dir, "locale", "en-us") - - -def read_samples(path): - samples = [] - with open(path) as fi: - for _ in fi.read().split("\n"): - if _ and not _.strip().startswith("#"): - samples += expand_options(_) - return samples - -samples = [] -for root, folders, files in os.walk(res_folder): - for f in files: - if f.endswith(".intent"): - samples += read_samples(join(root, f)) -skill._data["examples"] = list(set(samples)) - -has_android = exists(android_ui) -with open(skill_code) as f: - has_homescreen = f"{repo}.{author}.home" in f.read() - -if not exists(readme): - with open(readme, "w") as f: - f.write(skill.generate_readme()) - -if has_homescreen and not exists(desktopf): - with open(desktopf, "w") as f: - f.write(skill.desktop_file) - -if not exists(jsonf): - data = skill.json - with open(jsonf, "w") as f: - if not has_android or not has_homescreen: - data.pop("android") - if not has_homescreen: - data.pop("desktop") - data["desktopFile"] = False -else: - with open(jsonf) as f: - data = json.load(f) - -# set dev branch -data["branch"] = "dev" - -with open(jsonf, "w") as f: - json.dump(data, f, indent=4) diff --git a/scripts/release_skillstore.py b/scripts/release_skillstore.py deleted file mode 100644 index a176d89..0000000 --- a/scripts/release_skillstore.py +++ /dev/null @@ -1,41 +0,0 @@ -import json -from os.path import join, dirname - -base_dir = dirname(dirname(__file__)) - - -def get_version(): - """ Find the version of the package""" - version_file = join(base_dir, 'version.py') - major, minor, build, alpha = (None, None, None, None) - with open(version_file) as f: - for line in f: - if 'VERSION_MAJOR' in line: - major = line.split('=')[1].strip() - elif 'VERSION_MINOR' in line: - minor = line.split('=')[1].strip() - elif 'VERSION_BUILD' in line: - build = line.split('=')[1].strip() - elif 'VERSION_ALPHA' in line: - alpha = line.split('=')[1].strip() - - if ((major and minor and build and alpha) or - '# END_VERSION_BLOCK' in line): - break - version = f"{major}.{minor}.{build}" - if alpha and int(alpha) > 0: - version += f"a{alpha}" - return version - - -desktop_dir = join(base_dir, "res", "desktop") - -jsonf = join(desktop_dir, "skill.json") - -with open(jsonf) as f: - data = json.load(f) - -data["branch"] = "v" + get_version() - -with open(jsonf, "w") as f: - json.dump(data, f, indent=4) diff --git a/version.py b/version.py index 5ca9233..be3eeb2 100644 --- a/version.py +++ b/version.py @@ -1,6 +1,6 @@ # START_VERSION_BLOCK VERSION_MAJOR = 0 -VERSION_MINOR = 0 -VERSION_BUILD = 1 -VERSION_ALPHA = 3 +VERSION_MINOR = 1 +VERSION_BUILD = 0 +VERSION_ALPHA = 1 # END_VERSION_BLOCK