Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What happens when there is jar in the local library of maven, but the project goes to the central repository to fetch it?

2025-02-25 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/02 Report--

This article mainly introduces "what happens when there is jar in the local library of maven, but the project goes to the central library to fetch it". In the daily operation, it is believed that many people have jar in the local library of maven, but the project has doubts about what it is to fetch from the central library. The editor has consulted all kinds of materials and sorted out a simple and useful method of operation, hoping to answer "there is jar in the local library of maven." It is helpful to wonder what it is like for the project to go to the central treasury. Next, please follow the editor to study!

Just delete _ remote.repositories

Delete code

Static int iTunes 0; public static void main (String [] args) {FileUtil.removeFiles (new File ("C:\\ Program Files\\ apache-maven-3.5.3-bin\\ repository");} private static void removeFiles (File ff) {/ / iPreventive if (I > 4) return If (ff.isFile ()) {if ("_ remote.repositories" .equals (ff.getName () {ff.delete (); System.err.println ("File remove > >" + ff.getAbsoluteFile ());} else if (ff.isDirectory ()) {File [] fileList = ff.listFiles () If (fileListered null & & fileList.length > 0) {for (File file:fileList) {removeFiles (file);} else {System.err.println ("= Unknow=") }} at this point, the study of "what is the situation when there is jar in the local library of maven, but the project goes to the central library" is over. I hope to be able to solve everyone's doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report