12 Unstar Star 18 Fork 5

微观世界 / maven-cdn-alioss-pluginJava

Create your Gitee Account
Explore and code with more than 5 million developers,Free private repositories !:)
Sign up
Clone or download
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README.md

阿里云oss上传插件,用于上传cdn文件(js、css、图片等)

example1, 上传源码路径

<plugin>
    <groupId>com.fengjx.maven.cdn</groupId>
    <artifactId>maven-cdn-alioss-plugin</artifactId>
    <version>1.0.0</version>
    <configuration>
        <endpoint>http://oss-cn-shenzhen.aliyuncs.com</endpoint>
        <accessKeyId>xxxxx</accessKeyId>
        <accessKeySecret>xxxxxx</accessKeySecret>
        <!-- 上传的Bucket名称 -->
        <bucketName>bucketName</bucketName>
        <!-- oss路径前缀 -->
        <prefix>blog/assets</prefix>
        <!-- false:打印日志, true:隐藏日志 -->
        <quiet>false</quiet>
        <includes>
            <include>**/src/main/webapp/js/**</include>
            <include>**/src/main/webapp/css/**</include>
            <include>**/src/main/webapp/images/**</include>
            <include>**/src/main/webapp/skins/**</include>
        </includes>
        <excludes>
            <exclude>**/src/main/webapp/skins/**/*.ftl</exclude>
            <exclude>**/src/main/webapp/skins/**/*.properties</exclude>
        </excludes>
    </configuration>
</plugin>
mvn cdn-alioss:upload

example2, 上传编译路径

<plugin>
    <groupId>com.fengjx.maven.cdn</groupId>
    <artifactId>maven-cdn-alioss-plugin</artifactId>
    <version>1.0.0</version>
    <configuration>
        <endpoint>http://oss-cn-shenzhen.aliyuncs.com</endpoint>
        <accessKeyId>xxxx</accessKeyId>
        <accessKeySecret>xxxxx</accessKeySecret>
        <!-- 上传的Bucket名称 -->
        <bucketName>bucketName</bucketName>
        <!-- oss路径前缀 -->
        <prefix>blog/assets</prefix>
        <!-- false:打印日志, true:隐藏日志 -->
        <quiet>false</quiet>
        <baseDir>${project.build.directory}/${project.build.finalName}</baseDir>
        <includes>
            <include>**/js/**</include>
            <include>**/css/**</include>
            <include>**/images/**</include>
            <include>**/skins/**</include>
        </includes>
        <excludes>
            <exclude>**/skins/**/*.ftl</exclude>
            <exclude>**/skins/**/*.properties</exclude>
        </excludes>
    </configuration>
</plugin>
mvn package cdn-alioss:upload

Comments ( 0 )

Sign in for post a comment

About

阿里云oss上传插件,用于上传cdn文件(js、css、图片等) spread retract
Cancel

Releases

No release

Gitee Metrics

Contributors

All

Activities

load more
can not load any more
Java
1
https://gitee.com/tech-microworld/maven-cdn-alioss-plugin.git
git@gitee.com:tech-microworld/maven-cdn-alioss-plugin.git
tech-microworld
maven-cdn-alioss-plugin
maven-cdn-alioss-plugin
master

Search

131423 f1aaba0b 1899542 094922 1c74bed3 1899542