update commandline tool

This commit is contained in:
pengfei.zhou 2020-04-11 15:05:27 +08:00 committed by osborn
parent 34ff0ea7d9
commit ee864620c1
4 changed files with 21 additions and 6 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "doric-cli", "name": "doric-cli",
"version": "0.4.0", "version": "0.4.2",
"description": "Doric command line tools", "description": "Doric command line tools",
"main": "index.js", "main": "index.js",
"bin": { "bin": {

View File

@ -1,5 +1,12 @@
import groovy.json.JsonSlurper
apply plugin: 'com.android.application' apply plugin: 'com.android.application'
def model = new JsonSlurper().parse(new File(project.rootDir.getParent() + File.separator + "package.json"))
def doricSDKVersion = model.dependencies.doric.replace("^", "")
println("Doric Version:" + doricSDKVersion)
android { android {
compileSdkVersion 29 compileSdkVersion 29
buildToolsVersion "29.0.2" buildToolsVersion "29.0.2"
@ -28,8 +35,8 @@ android {
implementation fileTree(dir: 'libs', include: ['*.jar']) implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.1.0' implementation 'androidx.appcompat:appcompat:1.1.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3' implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation "pub.doric:core:__$Version__" implementation "pub.doric:core:$doricSDKVersion"
debugImplementation "pub.doric:devkit:__$Version__" debugImplementation "pub.doric:devkit:$doricSDKVersion"
} }
} }

View File

@ -1,3 +1,9 @@
require "json"
package = JSON.parse(File.read(File.join(__dir__, "../package.json")))
version = package['dependencies']["doric"]
version = version.gsub('^','')
source 'https://cdn.cocoapods.org/' source 'https://cdn.cocoapods.org/'
# Uncomment the next line to define a global platform for your project # Uncomment the next line to define a global platform for your project
# platform :ios, '9.0' # platform :ios, '9.0'
@ -7,6 +13,6 @@ target '__$__' do
use_frameworks! use_frameworks!
# Pods for __$__ # Pods for __$__
pod 'DoricCore', '~>__$Version__' pod 'DoricCore', "#{version}"
pod 'DoricDevkit', '~>__$Version__' pod 'DoricDevkit', "#{version}"
end end

View File

@ -31,6 +31,8 @@ cd $CURRENT_DIR/doric-web && npm version $CURRENT_VERSION --allow-same-version
## CLI ## CLI
echo $CURRENT_VERSION > $CURRENT_DIR/doric-cli/target/version echo $CURRENT_VERSION > $CURRENT_DIR/doric-cli/target/version
cd $CURRENT_DIR/doric-cli && npm version $CURRENT_VERSION --allow-same-version
# git save # git save
cd $CURRENT_DIR/ cd $CURRENT_DIR/