eclipse实现JavaWeb项目 增量打包

eclipse插件 创建java web增量更新包 一、使用条件 1、eclipse (eclipse 4.0以上) 2、版本管理用的svn 3、项目存在于eclipse工作空间下 二、使用方法 1、将下载的jar 放入eclipse\dropins下 2、重启eclipse 菜单栏会出现 打包 字样 3、填写svn用户和密码 4、点击添加 填写项目的svn路径 ,填写项目在本地的编译路径(照示例填写),填写WebRoot名称,填写java目录名称(一般为src),如果svn有用过主干分支,在字符串替换处填写/trunk:/ 点击保存 点击确定打包 5、填写一次后,以后可以直接打开使用 6、还有其它功能,可以用的时候试着研究一下 立即下载
   很多情况下,项目是不允许全量发布的,所以你得把有做修改的文件一个个挑出来,如果有成千上百的文件,你是不是要头大了? 以下方法应该可以让你得到解救!前提是你是用装有svn plugin的eclipse上做开发。

 

      第一步,用svn生成项目的补丁文件。

     

 

选中你需要增量升级的文件,点击完成。

 

       

   运行如下代码

 

Java代码  收藏代码
  1. package verysoft.freepath;  
  2. import java.io.BufferedInputStream;  
  3. import java.io.BufferedOutputStream;  
  4. import java.io.BufferedReader;  
  5. import java.io.File;  
  6. import java.io.FileInputStream;  
  7. import java.io.FileOutputStream;  
  8. import java.io.IOException;  
  9. import java.io.InputStreamReader;  
  10. import java.util.ArrayList;  
  11. import java.util.List;  
  12.   
  13. public class FreePatchUtil {  
  14.   
  15.     public static String patchFile="D:/patch.txt";//补丁文件,由eclipse svn plugin生成  
  16.       
  17.     public static String projectPath="D:/workspace/FordClubJeeCms";//项目文件夹路径  
  18.       
  19.     public static String webContent="WebContent";//web应用文件夹名  
  20.       
  21.     public static String classPath="D:/workspace/FordClubJeeCms/build";//class存放路径  
  22.       
  23.     public static String desPath="C:/Users/xuwen/Desktop/update_pkg";//补丁文件包存放路径  
  24.       
  25.     public static String version="20140711";//补丁版本  
  26.       
  27.       
  28.     /** 
  29.      * @param args 
  30.      * @throws Exception  
  31.      */  
  32.     public static void main(String[] args) throws Exception {  
  33.         copyFiles(getPatchFileList());  
  34.     }  
  35.       
  36.     public static List<String> getPatchFileList() throws Exception{  
  37.         List<String> fileList=new ArrayList<String>();  
  38.         FileInputStream f = new FileInputStream(patchFile);   
  39.         BufferedReader dr=new BufferedReader(new InputStreamReader(f,"utf-8"));  
  40.         String line;  
  41.         while((line=dr.readLine())!=null){   
  42.             if(line.indexOf("Index:")!=-1){  
  43.                 line=line.replaceAll(" ","");  
  44.                 line=line.substring(line.indexOf(":")+1,line.length());  
  45.                 fileList.add(line);  
  46.             }  
  47.         }   
  48.         return fileList;  
  49.     }  
  50.       
  51.     public static void copyFiles(List<String> list){  
  52.           
  53.         for(String fullFileName:list){  
  54.             if(fullFileName.indexOf("src/")!=-1){//对源文件目录下的文件处理  
  55.                 String fileName=fullFileName.replace("src","");  
  56.                 fullFileName=classPath+fileName;  
  57.                 if(fileName.endsWith(".java")){  
  58.                     fileName=fileName.replace(".java",".class");  
  59.                     fullFileName=fullFileName.replace(".java",".class");  
  60.                 }  
  61.                 String tempDesPath=fileName.substring(0,fileName.lastIndexOf("/"));  
  62.                 String desFilePathStr=desPath+"/"+version+"/WEB-INF/classes"+tempDesPath;  
  63.                 String desFileNameStr=desPath+"/"+version+"/WEB-INF/classes"+fileName;  
  64.                 File desFilePath=new File(desFilePathStr);  
  65.                 if(!desFilePath.exists()){  
  66.                     desFilePath.mkdirs();  
  67.                 }  
  68.                 copyFile(fullFileName, desFileNameStr);  
  69.                 System.out.println(fullFileName+"复制完成");  
  70.             }else{//对普通目录的处理  
  71.                 String desFileName=fullFileName.replaceAll(webContent,"");  
  72.                 fullFileName=projectPath+"/"+fullFileName;//将要复制的文件全路径  
  73.                 String fullDesFileNameStr=desPath+"/"+version+desFileName;  
  74.                 String desFilePathStr=fullDesFileNameStr.substring(0,fullDesFileNameStr.lastIndexOf("/"));  
  75.                 File desFilePath=new File(desFilePathStr);  
  76.                 if(!desFilePath.exists()){  
  77.                     desFilePath.mkdirs();  
  78.                 }  
  79.                 copyFile(fullFileName, fullDesFileNameStr);  
  80.                 System.out.println(fullDesFileNameStr+"复制完成");  
  81.             }  
  82.               
  83.         }  
  84.           
  85.     }  
  86.   
  87.     private static void copyFile(String sourceFileNameStr, String desFileNameStr) {  
  88.         File srcFile=new File(sourceFileNameStr);  
  89.         File desFile=new File(desFileNameStr);  
  90.         try {  
  91.             copyFile(srcFile, desFile);  
  92.         } catch (IOException e) {  
  93.             e.printStackTrace();  
  94.         }  
  95.     }  
  96.       
  97.   
  98.       
  99.       
  100.     public static void copyFile(File sourceFile, File targetFile) throws IOException {  
  101.         BufferedInputStream inBuff = null;  
  102.         BufferedOutputStream outBuff = null;  
  103.         try {  
  104.             // 新建文件输入流并对它进行缓冲  
  105.             inBuff = new BufferedInputStream(new FileInputStream(sourceFile));  
  106.   
  107.             // 新建文件输出流并对它进行缓冲  
  108.             outBuff = new BufferedOutputStream(new FileOutputStream(targetFile));  
  109.   
  110.             // 缓冲数组  
  111.             byte[] b = new byte[1024 * 5];  
  112.             int len;  
  113.             while ((len = inBuff.read(b)) != -1) {  
  114.                 outBuff.write(b, 0, len);  
  115.             }  
  116.             // 刷新此缓冲的输出流  
  117.             outBuff.flush();  
  118.         } finally {  
  119.             // 关闭流  
  120.             if (inBuff != null)  
  121.                 inBuff.close();  
  122.             if (outBuff != null)  
  123.                 outBuff.close();  
  124.         }  
  125.     }  
  126.       
  127. }  

 

注意,以下部份请按照实际情况填写

 

Java代码  收藏代码
  1. public static String patchFile="D:/patch.txt";//补丁文件,由eclipse svn plugin生成  
  2.   
  3. public static String projectPath="D:/workspace/FordClubJeeCms";  
  4.   
  5. public static String webContent="WebContent";//web应用文件夹名  
  6.   
  7. public static String classPath="D:/workspace/FordClubJeeCms/build";//class存放路径  
  8.   
  9. public static String desPath="C:/Users/xuwen/Desktop/update_pkg";//补丁文件包存放路径  
  10.   
  11. public static String version="20140711";//补丁版本  

 

   好了,运行后得到结果

 

 

 如果有多个人都修改了代码,那么每个人在提交代码之前先按第一步生成补丁文件再提交。当所有人都提交代码后,在一台电脑上更新所有代码,再在这台电脑上用以上代码运行所有人生成的补丁文件即可。

JAVA增量包打包工具 项目增量补丁包神器桌面版:全自动web增量打包发版,支持gitee/git/svn,支持多模块项目 立即下载

相关推荐

ideploy 打包工具javaweb 增量打包工具

ideploy 打包工具javaweb 增量打包工具

eclipse实现JavaWeb应用增量打包

很多情况下,项目是不允许全量发布的,所以你得把有做修改的文件一个个挑出来,如果有成千上百的文件,你是不是要头大了? 以下方法应该可以让你得到解救!前提是你是用装有svn plugin的eclipse上做开发。 第一步,用svn生成项目的补丁文件。选中你需要增量升级的文件,点击完成。 运行如下代码Java代码...

weixin_34206899的博客 334

【论文阅读】AU检测|《Deep Adaptive Attention for Joint Facial Action Unit Detection and Face Alignment》

摘要 本文旨在从大量没有人工标注的视频中学习用于面部动作单元检测的区分表示。受面部动作是面部肌肉运动这一事实的启发,论文将这些运动描述为不同帧中两幅面部图像之间的转换,并将其用作学习表示的自我监控信号。但是,在不受控制的情况下,这种转换是由面部动作和头部运动引起的。为了消除头部运动的影响,我们提出了一个双圈自动编码器(TCAE),它可以解开面部动作相关运动和头部运动相关运动。具体而言,TCAE被训练成分别将源面部的面部动作和头部姿态改变为目标面部的面部动作和头部姿态。我们的实验验证了TCAE解耦运动的能力。

Celine的博客 4555

Eclipse实现JavaWeb项目增量打包

                               MyEclipse增量补丁生成工具使用教程 提交重要代码 生成差异文件 选择当前工程,右键、进入Compare With ,点击 分支\标记,开始生成revision.diff文件到桌面 3、打包前整理工程代码结构 将下面的文件拷贝到本地代码目录下,以branches_vcompass_ch工程为例    将b...

weberhuangxingbo的博客 1603

从ViT到Swin Transformer:一文搞懂Transformer在CV中的进化史(附实战代码)

本文系统梳理了Transformer在计算机视觉领域的演进历程,从开创性的Vision Transformer(ViT)引入全局注意力机制,到DETR实现端到端目标检测,再到里程碑式的Swin Transformer通过滑动窗口和层次化设计高效桥接CNN与ViT。文章深入剖析了各模型的核心思想、技术突破与实战应用,并提供了可运行的代码示例,帮助读者从理论到实践全面掌握这一关键技术脉络。

cola5的博客 713

OpenClaw Windows 安装指南

好的,我来一步一步带你在 Windows 上安装 OpenClaw。

m0_60605453的博客 553

eclipse增量打包文件

eclipse增量打包

weixin_67124418的博客 414

在ubuntu20.04中安装MATLAB时常见问题及解决方法

   如果你刚装完ubuntu20.04,这时你想要安装MATLAB2021A,在输入命令./install进行安装时,可能会报以下错误:    terminate called after throwing an instance of ‘JailContainerException’ what(): Error: 88: No JRE version parsed from/media/jzx/MATHWORKS_R2021A/sys /java/jre/glnxa64/jre/release   

慕羽★的博客 1万+

java增量补丁_eclipse实现JavaWeb项目 增量打包

packageverysoft.freepath;importjava.io.BufferedInputStream;importjava.io.BufferedOutputStream;importjava.io.BufferedReader;importjava.io.File;importjava.io.FileInputStream;importjava.io.FileOut...

weixin_36218209的博客 411

基于深度学习的涂胶缺陷类型检测:数据集处理与YOLOv8模型实现

本文提出了一种基于YOLOv8深度学习的涂胶缺陷检测系统,针对断胶、溢胶、缺胶、气泡及胶条宽度异常等常见缺陷类型,实现了从数据采集到模型部署的完整解决方案。系统采用工业相机采集涂胶图像,通过多形态数据增强策略解决样本稀缺问题,利用YOLOv8框架实现高效检测。相比传统人工目检和规则式机器视觉方法,该系统在检测精度(mAP达97.5%)和实时性(单图检测耗时0.038秒)方面表现优异,可满足智能制造场景下的涂胶质量检测需求。

huanghm88的专栏 278

无人船 | 基于ROS的轻量级多无人艇自主导航仿真框架

无人水面艇USV是海上自主无人系统的关键组成部分,在民用、军用领域应用广泛,例如海上救援、水质测量、扫雷反潜等,因此对USV导航算法的研究具有重要意义。为了便于进行USV相关算法的验证与部署,本文介绍的这套基于ROS的多无人艇的自主导航仿真平台,轻量化地实现了建图、规划、控制等多种功能,同时自研框架保证了功能的高度可拓展和可定制

FRIGIDWINTER的博客 8016

java怎么打增量包_eclipse实现JavaWeb应用增量打包

很多情况下,项目是不允许全量发布的,所以你得把有做修改的文件一个个挑出来,如果有成千上百的文件,你是不是要头大了? 以下方法应该可以让你得到解救!前提是你是用装有svn plugin的eclipse上做开发。第一步,用svn生成项目的补丁文件。选中你需要增量升级的文件,点击完成。运行如下代码package verysoft.freepath;import java.io.BufferedInput...

weixin_39648539的博客 762

【Dify(v1.x) 核心源码深入解析】File 模块

文件模型(File Model)定义了文件的核心属性,如文件类型、传输方法、相关标识符等,是整个文件处理流程的数据基础。文件解析器(UploadFileParser)负责解析上传的文件,根据配置决定以何种方式(URL 或 Base64)提供图像数据。工具文件解析器(ToolFileParser)专注于工具文件的管理,提供工具文件管理器的获取接口。签名验证与生成(helpers.py)包含文件 URL 签名的生成与验证逻辑,确保文件访问的安全性。文件管理器(file_manager.py)

670

java打增量包_eclipse实现JavaWeb应用增量打包

package verysoft.freepath;import java.io.BufferedInputStream;import java.io.BufferedOutputStream;import java.io.BufferedReader;import java.io.File;import java.io.FileInputStream;import java.io.FileOut...

weixin_42298802的博客 346

VisionTransformer改进(11):结合CoordAtt注意力机制

​​CoordAtt模块​​:一个轻量级的坐标注意力机制​​ViT模型​​:基于标准Vision Transformer架构,但集成了CoordAtt模块模型最终通过CNNModel函数封装,虽然名称是CNN,但实际上是一个Transformer模型。引入了轻量级的CoordAtt注意力机制,增强了模型对空间位置信息的捕捉能力保持了ViT的主要优势,同时通过注意力机制提升了特征表示能力设计简洁高效,适合作为基础模型进行进一步研究和应用。

2401_82355416的博客 702

RU DOS版、EFI版32bit/64bit BIOS常用工具

DOS版、EFI版的RU工具,可用来查看IO、MEM、PCI、SMBIOS等资源。亲测在EFI SHELL下可用。

java增量打包脚本_eclipse实现JavaWeb应用增量打包

很多情况下,项目是不允许全量发布的,所以你得把有做修改的文件一个个挑出来,如果有成千上百的文件,你是不是要头大了? 以下方法应该可以让你得到解救!前提是你是用装有svn plugin的eclipse上做开发。第一步,用svn生成项目的补丁文件。 选中你需要增量升级的文件,点击完成。 运行如下代码package verysoft.freepath;import java.io.BufferedInp...

weixin_33531560的博客 197

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

上一篇: @Scheduled注解 定时任务 cron表达式详解
下一篇: maven全局配置文件settings.xml详解
lyhjava
博客等级 码龄11年 15粉丝 1原创
评论 1
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值