Skip to content

Commit

Permalink
new beta version 3.4.2-magnesium-beta
Browse files Browse the repository at this point in the history
  • Loading branch information
danieleteti committed Jan 9, 2024
1 parent 40b709b commit dbe6382
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 4 deletions.
15 changes: 14 additions & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [


{
"name": "Python TASK generate-nullable",
Expand All @@ -26,14 +27,26 @@
"console": "integratedTerminal"
},
{
"name": "Python TASK build-samples",
"name": "build-samples",
"type": "python",
"request": "launch",
"module": "invoke",
"args": [
"build-samples"
],
"console": "integratedTerminal"
},
{
"name": "release",
"type": "python",
"request": "launch",
"module": "invoke",
"args": [
"release",
"--skip-build",
"--skip-tests"
],
"console": "integratedTerminal"
}
]
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# DelphiMVCFramework ![Mentioned in Awesome Go](https://awesome.re/mentioned-badge.svg) ![GitHub All Releases](https://img.shields.io/github/downloads/danieleteti/delphimvcframework/total?label=Downloads)

![](https://img.shields.io/badge/stable-dmvcframework--3.4.1--sodium-blue)
![](https://img.shields.io/badge/beta-dmvcframework--3.5.0--magnesium--beta-red)
![](https://img.shields.io/badge/beta-dmvcframework--3.4.2--magnesium--beta-red)

<!-- START doctoc generated TOC please keep comment here to allow auto update -->
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
Expand Down
2 changes: 1 addition & 1 deletion sources/dmvcframeworkbuildconsts.inc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
const
DMVCFRAMEWORK_VERSION = '3.4.1-sodium';
DMVCFRAMEWORK_VERSION = '3.4.2-magnesium-beta';
23 changes: 22 additions & 1 deletion tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -393,15 +393,36 @@ def tests64(ctx):
def tests(ctx):
pass

def get_version_from_file():
with open(r".\sources\dmvcframeworkbuildconsts.inc") as f:
lines = f.readlines()
res = [x for x in lines if "DMVCFRAMEWORK_VERSION" in x]
if len(res) != 1:
raise Exception("Cannot find DMVCFRAMEWORK_VERSION in dmvcframeworkbuildconsts.inc file")
version_line: str = res[0]
version_line = version_line.strip(" ;\t")
pieces = version_line.split("=")
if len(pieces) != 2:
raise Exception("Version line in wrong format in dmvcframeworkbuildconsts.inc file: " + version_line)
version = pieces[1].strip("' ")
if not 'framework' in version:
version = "dmvcframework-" + version
if "beta" in version.lower():
print(Fore.RESET + Fore.RED + "WARNING - BETA VERSION: " + version + Fore.RESET)
else:
print(Fore.RESET + Fore.GREEN + "BUILDING VERSION: " + version + Fore.RESET)
return version

@task()
def release(
ctx,
version="DEBUG",
skip_build=False,
skip_tests=False,
):
"""Builds all the projects, executes integration tests and prepare the release"""

version = get_version_from_file()

init_build(version)

if not skip_tests:
Expand Down

0 comments on commit dbe6382

Please sign in to comment.