mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-02-19 13:54:25 +01:00
store and retrieve app version in package.json
This commit is contained in:
parent
6e56ac4286
commit
0aa75488fa
@ -1 +0,0 @@
|
||||
2.6.7
|
@ -1,5 +1,6 @@
|
||||
# Changelog Fab Manager
|
||||
|
||||
- Nom using standard [package.json](package.json) file to save application version number
|
||||
- Fix a bug: on small screens, display of button "change group" overflow
|
||||
|
||||
## v2.6.7 2018 October 4
|
||||
|
@ -4,7 +4,8 @@ class API::VersionController < API::ApiController
|
||||
|
||||
def show
|
||||
authorize :version
|
||||
version = File.read('.fabmanager-version')
|
||||
render json: {version: version}, status: :ok
|
||||
package = File.read('package.json')
|
||||
version = JSON.parse(package)['version']
|
||||
render json: { version: version }, status: :ok
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user