I want to do some analysis on some old code and need to be able to pop a stream as of a specific date. I don't want to create a snapshot or workspace, I just need all the source code as of six months ago. Is there an easy way to do it?
At this point in my research I'm thinking I might need to use the hist
command to get the latest transaction as of a given date, create a reftree, then do an update to that transaction number. However, when I do that I get a "Given update transaction out of range" error on the update command.
Incidentally, AccuRev 4.9 adds the functionality to "pop -t" and specify a point-in-time to populate the code "as of". This should address what you're looking for going forward...
create a child stream with a time rule. Then pop from that. You can do it from the GUI. Here's the CLI.
$ mkdir code && cd code
$ accurev mkstream -s <Child> -b <Parent> -t "<Time>" # format: YYYY/MM/DD HH:MM:SS
$ accurev pop -R -v <Child> -L . .
If you name it generically, you can reparent/reuse elsewhere to do your time-based pops. So for the most poart, you only need one stream (e.g. you don't need a time stream for every hist based pop).
$ accurev chstream -s <Child> -b <NewParent> -t "<NewTime>"
HTH - dave
You can do this from the command line without having to create a stream as follows
accurev pop -R -v stream_name -L c:\MyDirectory -t "2012/11/01 00:00:00" \.\
This will retrieve all the files from the stream stream_name
as they were on Nov 1st 2012 and place them into c:\MyDirectory
The -t
parameter can also take a transaction number, so you could specify -t 12345
. The final parameter \.\
means the root - you can specify any path in Accurev, such as \.\MyProject\src
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With