roippi
Developer
Okay, that little change makes me ~infinity percent happier -
Haven't implemented svn update yet, but that's like 5 lines of code.
Here's the one thing that's still up in the air for me. To be clear on the whole process, we checkout and keep a Working Copy in svn/projectname/. We then copy the files and directories contained therein to the appropriate places in the mafia subfolders.
Left like that, this is going to result in some unintuitive behavior for lay users. Say they don't want a relay script any more, so they delete it from /relay... only to find that it keeps reappearing. It's not intuitive that you need to delete both the copy in /relay and the project folder in /svn. And, hey, maybe someone only wants half of a project, so they delete the other half of it. They don't want the stuff they deleted to keep reappearing.
Further complicating things is how the Working Copy model works. If you delete an individual file from the working copy, doing svn update will just restore it. And script maintainers can add new files to their project, which will similarly get pulled down with an svn update. We want those to be pushed to mafia subdirectories, but not any files that the user has deleted.
This is all possible to implement of course. SVN knows when it adds/updates a file (see the lines in the operation above that start with A), I just need to hand that information off to the method that pushes files to the mafia subdirectories. Also I think svn checkout should always push all files, whereas svn update should push new files and updated files iff the file currently exists in the destination subdirectory.
Whew. Lot to do still.
Code:
> svn checkout https://svn.code.sf.net/p/mafiasvntest/code/myvalidproject1/
Validating repo...
Repo validated.
C:\Users\Ben\workspace\kolmafia\svn\mafiasvntest-myvalidproject1
A https://svn.code.sf.net/p/mafiasvntest/code/myvalidproject1/scripts
A https://svn.code.sf.net/p/mafiasvntest/code/myvalidproject1/scripts/valid.txt
https://svn.code.sf.net/p/mafiasvntest/code/myvalidproject1
At revision 2
Successfully checked out working copy.
Haven't implemented svn update yet, but that's like 5 lines of code.
Here's the one thing that's still up in the air for me. To be clear on the whole process, we checkout and keep a Working Copy in svn/projectname/. We then copy the files and directories contained therein to the appropriate places in the mafia subfolders.
Left like that, this is going to result in some unintuitive behavior for lay users. Say they don't want a relay script any more, so they delete it from /relay... only to find that it keeps reappearing. It's not intuitive that you need to delete both the copy in /relay and the project folder in /svn. And, hey, maybe someone only wants half of a project, so they delete the other half of it. They don't want the stuff they deleted to keep reappearing.
Further complicating things is how the Working Copy model works. If you delete an individual file from the working copy, doing svn update will just restore it. And script maintainers can add new files to their project, which will similarly get pulled down with an svn update. We want those to be pushed to mafia subdirectories, but not any files that the user has deleted.
This is all possible to implement of course. SVN knows when it adds/updates a file (see the lines in the operation above that start with A), I just need to hand that information off to the method that pushes files to the mafia subdirectories. Also I think svn checkout should always push all files, whereas svn update should push new files and updated files iff the file currently exists in the destination subdirectory.
Whew. Lot to do still.