[master] make version info update live instead of requiring a restart in
This commit is contained in:
parent
d9a601328c
commit
897ec0d0c1
@ -56,3 +56,4 @@ del "%SolutionDir%Publish\WindowsPrerelease\*pdb"
|
|||||||
|
|
||||||
echo making start script
|
echo making start script
|
||||||
@echo dotnet IW4MAdmin.dll > "%SolutionDir%Publish\WindowsPrerelease\StartIW4MAdmin.cmd"
|
@echo dotnet IW4MAdmin.dll > "%SolutionDir%Publish\WindowsPrerelease\StartIW4MAdmin.cmd"
|
||||||
|
@echo dotnet IW4MAdmin.dll > "%SolutionDir%Publish\Windows\StartIW4MAdmin.cmd"
|
||||||
|
@ -6,6 +6,7 @@ using System.Globalization;
|
|||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace IW4MAdmin.Application.Localization
|
namespace IW4MAdmin.Application.Localization
|
||||||
{
|
{
|
||||||
|
@ -6,7 +6,6 @@ from flask import Flask
|
|||||||
from flask_restful import Resource, Api
|
from flask_restful import Resource, Api
|
||||||
from flask_jwt_extended import JWTManager
|
from flask_jwt_extended import JWTManager
|
||||||
from master.context.base import Base
|
from master.context.base import Base
|
||||||
import json
|
|
||||||
|
|
||||||
app = Flask(__name__)
|
app = Flask(__name__)
|
||||||
app.config['JWT_SECRET_KEY'] = 'my key!'
|
app.config['JWT_SECRET_KEY'] = 'my key!'
|
||||||
@ -14,7 +13,7 @@ app.config['PROPAGATE_EXCEPTIONS'] = True
|
|||||||
jwt = JWTManager(app)
|
jwt = JWTManager(app)
|
||||||
api = Api(app)
|
api = Api(app)
|
||||||
ctx = Base()
|
ctx = Base()
|
||||||
config = json.load(open('./master/config/master.json'))
|
#config = json.load(open('./master/config/master.json'))
|
||||||
|
|
||||||
import master.routes
|
import master.routes
|
||||||
import master.views
|
import master.views
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{
|
{
|
||||||
"current-version-stable": 2.0,
|
"current-version-stable": 2.1,
|
||||||
"current-version-prerelease": 2.1
|
"current-version-prerelease": 2.1
|
||||||
}
|
}
|
@ -1,8 +1,9 @@
|
|||||||
from flask_restful import Resource
|
from flask_restful import Resource
|
||||||
from master import config
|
import json
|
||||||
|
|
||||||
class Version(Resource):
|
class Version(Resource):
|
||||||
def get(self):
|
def get(self):
|
||||||
|
config = json.load(open('./master/config/master.json'))
|
||||||
return {
|
return {
|
||||||
'current-version-stable' : config['current-version-stable'],
|
'current-version-stable' : config['current-version-stable'],
|
||||||
'current-version-prerelease' : config['current-version-prerelease']
|
'current-version-prerelease' : config['current-version-prerelease']
|
||||||
|
Loading…
Reference in New Issue
Block a user