Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Rockbox Ports are now being developed for various digital audio players!

+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  Starting Development and Compiling
| | |-+  Reverting to clean SVN
« previous next »
  • Print
Pages: [1]

Author Topic: Reverting to clean SVN  (Read 6574 times)

Offline major_works

  • Member
  • *
  • Posts: 32
Reverting to clean SVN
« on: January 08, 2008, 10:14:04 PM »
They say the only dumb questions are the ones you don't ask,  aso here goes:

Say I've checked out the current revision of SVN and then apply a bunch of patches. Something goes awry, though, and I want to revert my local repository to its original state.

How do I apply the revert command in Cygwin to do this?
Logged

Offline cool_walking_

  • Rockbox Expert
  • Member
  • *
  • Posts: 695
Re: Reverting to clean SVN
« Reply #1 on: January 09, 2008, 01:49:13 AM »
I never use the CLI for SVN, but it looks like "svn revert -R *" in the rockbox trunk directory should do it.

You might want to look into TortoiseSVN.
Logged

Offline GodEater

  • Member
  • *
  • Posts: 2829
Re: Reverting to clean SVN
« Reply #2 on: January 09, 2008, 03:31:08 AM »
Quote from: cool_walking_ on January 09, 2008, 01:49:13 AM
I never use the CLI for SVN, but it looks like "svn revert -R *" in the rockbox trunk directory should do it.

Nearly right :)

"svn revert -R ."
Logged

Read The Manual Please

Offline linuxstb

  • Developer
  • Member
  • *
  • Posts: 1163
Re: Reverting to clean SVN
« Reply #3 on: January 09, 2008, 06:30:34 AM »
One thing you need to be aware of is that "svn revert" will only touch files that are part of SVN.  This means that if your patches have created new files, then those new files will be unknown to SVN, and hence still sitting on your disk.

This can cause problems if you try to apply the patch again.

The only solution I know is to type "svn status" to see files listed with a ?, and manually delete them.  I normally do that separately within the "apps" and "firmware" directories.
Logged

Offline cool_walking_

  • Rockbox Expert
  • Member
  • *
  • Posts: 695
Re: Reverting to clean SVN
« Reply #4 on: January 09, 2008, 07:01:46 AM »
"svn clean" seemed like a natural name for that, so I googled it, and...

http://svn.collab.net/repos/svn/trunk/contrib/client-side/svn-clean

I'm assuming it actually works and isn't a work in progress since it says Copyright 2004.
Logged

Offline Mad Cow

  • Member
  • *
  • Posts: 445
Re: Reverting to clean SVN
« Reply #5 on: January 09, 2008, 10:42:22 PM »
I do it another way. I keep a clean copy of the source in another dir and just replace whatever files I need to revert, I have a big hard drive so it's not an issue keeping 2 copies of the source.
Logged
iRiver H10 5GB, Gigabeat F40, Gigabeat S60, all rockboxed. :P

Offline dionoea

  • Member
  • *
  • Posts: 30
Re: Reverting to clean SVN
« Reply #6 on: January 10, 2008, 09:59:55 AM »
Quote from: Mad Cow on January 09, 2008, 10:42:22 PM
I do it another way. I keep a clean copy of the source in another dir and just replace whatever files I need to revert, I have a big hard drive so it's not an issue keeping 2 copies of the source.

Then you're in fact keeping 4 copies of each file on your disk, since svn already saves the "clean" version in the .svn directory (so it can run svn diff without having to ask the server). (Just my 2 cents...)
Logged

Offline Mad Cow

  • Member
  • *
  • Posts: 445
Re: Reverting to clean SVN
« Reply #7 on: January 10, 2008, 04:15:04 PM »
SVN reverting never worked right for me, so I just did it that way. It works and I don't care if it takes up alot of space.
Logged
iRiver H10 5GB, Gigabeat F40, Gigabeat S60, all rockboxed. :P

Offline major_works

  • Member
  • *
  • Posts: 32
Re: Reverting to clean SVN
« Reply #8 on: January 12, 2008, 09:54:11 PM »
Quote from: cool_walking_ on January 09, 2008, 07:01:46 AM
"svn clean" seemed like a natural name for that, so I googled it, and...

http://svn.collab.net/repos/svn/trunk/contrib/client-side/svn-clean

I'm assuming it actually works and isn't a work in progress since it says Copyright 2004.

OK, next dumb question(s):

Where should this program reside? The top line says:

#!/usr/bin/perl

Is that the directory in which I should place it? Would I simply invoke it from the command line with "svn clean?"
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Reverting to clean SVN
« Reply #9 on: January 12, 2008, 09:57:17 PM »
A #! means "run this script using this program". It tells your shell how to interpret it basically. When you run the script, it'll automatically run using perl rather than a default. That shouldn't affect where you put the script.
Logged

Offline major_works

  • Member
  • *
  • Posts: 32
Re: Reverting to clean SVN
« Reply #10 on: January 12, 2008, 10:12:22 PM »
Quote from: Llorean on January 12, 2008, 09:57:17 PM
A #! means "run this script using this program". It tells your shell how to interpret it basically. When you run the script, it'll automatically run using perl rather than a default. That shouldn't affect where you put the script.

OK, thanks. Was I correct, though, in surmising that it'd be invoked with "svn clean?"
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Reverting to clean SVN
« Reply #11 on: January 12, 2008, 10:14:29 PM »
Nah, you're actually executing the script. If it's in your path, it'd be svn-clean, if you put it in the folder you want to use it in, it'd be ./svn-clean from within that folder. At least, I think. I haven't actually *read* the script. :)
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  Starting Development and Compiling
| | |-+  Reverting to clean SVN
 

  • SMF 2.0.18 | SMF © 2021, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.035 seconds with 18 queries.