From d953676405d40aad79065f1b8821c894fa8bf163 Mon Sep 17 00:00:00 2001 From: Eason Date: Thu, 15 Apr 2021 19:42:52 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9gradle?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 1 + README.md | 42 +++++++++++-------- build.gradle | 3 ++ entry/build.gradle | 3 +- library/build.gradle | 1 + .../library/widget/utils/AttrUtils.java | 1 + 6 files changed, 32 insertions(+), 19 deletions(-) diff --git a/.gitignore b/.gitignore index 603b140..c598684 100644 --- a/.gitignore +++ b/.gitignore @@ -12,3 +12,4 @@ /captures .externalNativeBuild .cxx +upload.gradle diff --git a/README.md b/README.md index 730b885..9ba7d53 100644 --- a/README.md +++ b/README.md @@ -32,24 +32,30 @@ 通过继承原生控件,设置自定义属性,例如 圆角、边框、渐变、背景等 ## 安装教程 - 1.下载RWidgetHelper的har包 rwidgethelper.har(位于:) - - 2.启动 DevEco Studio,将下载的har包,导入工程目录“entry->libs”下。 - - 3.在moudle级别下的build.gradle文件中添加依赖,在dependences标签中增加对libs目录下har包的引用。 - - - ``` - dependencies { - implementation fileTree(dir: 'libs', include: ['*.jar', '*.har']) - …… -} -``` - -在sdk5,DevEco Studio2.1 beta3下项目可直接运行 -如无法运行,删除项目.gradle,.idea,build,gradle,build.gradle文件 -并依据自己的版本创建新项目,将新项目的对应文件复制到根目录下 + 1.在项目根目录下的build.gradle文件中, + + ``` + + allprojects { + repositories { + maven { + url 'https://s01.oss.sonatype.org/content/repositories/snapshots/' + } + } + } + ``` + 2.在entry模块的build.gradle文件中, + + ``` + dependencies { + implementation('com.gitee.chinasoft_ohos:RWidgetHelper:0.0.1-SNAPSHOT') + ...... + } + ``` + 在sdk5,DevEco Studio2.1 beta3下项目可直接运行 + 如无法运行,删除项目.gradle,.idea,build,gradle,build.gradle文件, + 并依据自己的版本创建新项目,将新项目的对应文件复制到根目录下 ## 使用说明 1.基于继承鸿蒙原生UI组件实现圆角边框字体颜色渐变等效果 @@ -177,7 +183,7 @@ VirusTotal病毒安全检测通过 #### 版本迭代 -- v0.0.1-alpha +- 0.0.1-SNAPSHOT ## 版权和许可信息 diff --git a/build.gradle b/build.gradle index b83f1bc..c177872 100644 --- a/build.gradle +++ b/build.gradle @@ -26,6 +26,9 @@ buildscript { allprojects { repositories { + maven { + url 'https://s01.oss.sonatype.org/content/repositories/snapshots/' + } maven { url 'https://mirrors.huaweicloud.com/repository/maven/' } diff --git a/entry/build.gradle b/entry/build.gradle index dc1e3f8..c080591 100644 --- a/entry/build.gradle +++ b/entry/build.gradle @@ -9,5 +9,6 @@ ohos { dependencies { implementation fileTree(dir: 'libs', include: ['*.jar', '*.har']) testCompile 'junit:junit:4.12' - implementation project(':library') + implementation('com.gitee.chinasoft_ohos:RWidgetHelper:0.0.1-SNAPSHOT') + } diff --git a/library/build.gradle b/library/build.gradle index 4291700..ae3efac 100644 --- a/library/build.gradle +++ b/library/build.gradle @@ -1,4 +1,5 @@ apply plugin: 'com.huawei.ohos.library' + ohos { compileSdkVersion 5 defaultConfig { diff --git a/library/src/main/java/com/ruffian/library/widget/utils/AttrUtils.java b/library/src/main/java/com/ruffian/library/widget/utils/AttrUtils.java index 68dd6cc..c120932 100644 --- a/library/src/main/java/com/ruffian/library/widget/utils/AttrUtils.java +++ b/library/src/main/java/com/ruffian/library/widget/utils/AttrUtils.java @@ -1,3 +1,4 @@ + /* * Copyright (C) 2021 The Chinese Software International Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); -- Gitee From f6817b8b3103ef2be48cb8a1305cd8039610034c Mon Sep 17 00:00:00 2001 From: Eason Date: Thu, 15 Apr 2021 19:45:17 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=97=A0=E7=94=A8?= =?UTF-8?q?=E7=B1=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- LICENSE | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 LICENSE diff --git a/LICENSE b/LICENSE deleted file mode 100644 index 9fdc080..0000000 --- a/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2021 CHINASOFT_OHOS - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. -- Gitee