IOS one-time add all files to SVN command, iossvn

Source: Internet
Author: User

IOS one-time add all files to SVN command, iossvn

I use terminal commands to use svn, but there are two troubles when using the terminal.

The first one is that you cannot add all files at a time. Finally, I found such a command on the Internet.

Svn st | awk '{if ($1 = "? ") {Print $2} '| xargs svn add


At first, I didn't know what it meant, so I felt quite helpful.

But this command cannot add an image file like home_image@2x.png, you need to add the "@" symbol behind the image

Today, because I want to upload a lot of images and it is inconvenient to add them one by one, I studied the awk command.

Finally, I understand that you only need to change the above command a little.

Svn st | awk '{if ($1 = "? ") {If (match ($0," @ ") {print $2" @ "} else {print $2 }}' | xargs svn add

Among them, match ($0, "@") is used to check that every row contains exactly @ others. It is different from the @ 2x.png file.


Record this and write it to yourself. Thank you for reprinting-LC

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.