Project

General

Profile

Feature #1892

cleanup unnecessary code, docs and project directories that are not core

Added by Greg Shah over 11 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:
8.00 h
billable:
No
vendor_id:
GCD
version_reported:
version_resolved:

Related issues

Blocked by Build and Source Control - Feature #1891: migrate P2J from CVS to BZR using the new migration scripts Closed 11/01/2012

History

#1 Updated by Greg Shah over 11 years ago

The design/, diagrams/ and testcases/ directories should each be moved from the core p2j project into their own project (of the same name) in the same top level location as the books, samples and so forth: p2j_repo/

Review all of the package.html files. Many of them have unnecessary content or old content. This stuff can be moved out of those html files and if necessary, checked into the non-core BZR projects somewhere.

#2 Updated by Greg Shah over 11 years ago

  • Subject changed from cleanup unnecessary code, docs and project directories that is not core to cleanup unnecessary code, docs and project directories that are not core

What other stuff is ripe for cleanup?

#3 Updated by Greg Shah over 11 years ago

In thinking about this work, I wish to create Bazaar projects in which the deleted stuff can be moved (see above). For example, I want to delete design/ from the p2j/ project and have all the contents (including history and prior versions...) in a Bazaar project of its own.

My key question: is there a reasonable way to do that?

I could duplicate the p2j project (literally, copy the directory including all the .bzr stuff), then delete everything except for the design/ directory. This should retain all the history and the top level directory can be named anything. BUT this new project would then still have all the P2J history in its .bzr metadata. And that stuff can always be brought back, which is NOT wanted.

Ideas?

#4 Updated by Adrian Lungu over 11 years ago

It seems the fast-import-filter will do it.

$ bzr help fast-import-filter
Purpose: Filter a fast-import stream to include/exclude files & directories.
Usage:   bzr fast-import-filter [SOURCE]

You can use the p2j.fi file generated by cvs2bzr or use fast-export on the current repository.

Should I make a test on this ?

#5 Updated by Greg Shah over 11 years ago

Yes, please test this.

#6 Updated by Adrian Lungu over 11 years ago

It worked:
1. filter the "fi" file to include only the design directory along with the history:

bzr fast-import-filter -i design/ p2j.fi > /tmp/design.fi

2. prepare the new repository( with the name "design" in my example. I did this to avoid the trunk directory creation.
md /path/to/bzrrepo/design
cd /path/to/bzrrepo/design
bzr init

3. import the fi file
bzr fast-import /tmp/design.fi /path/to/bzrrepo/design

You'll need the p2j.fi file generated on the conversion from the CVS.
p2j.fi could be found in the cvs2bzr-2.4.0/cvs2svn-tmp directory.

#7 Updated by Adrian Lungu over 11 years ago

The p2j.fi file could also be obtained from the current bazaar repository by:

cd /path/to/bzrrepo/p2j
bzr fast-export . p2j.fi

#8 Updated by Greg Shah over 11 years ago

I used the provided instructions and it worked well! I used the current bazaar repo and captured a new p2j.fi so that all recent changes were handled. Then I moved design/, diagrams/ and testcases/ out of p2j and into: /opt/code/p2j_repo/design/, /opt/code/p2j_repo/diagrams/ and /opt/code/p2j_repo/testcases/ respectively. Finally, I removed these directories from the p2j project and committed the change.

#9 Updated by Greg Shah over 11 years ago

  • Assignee set to Greg Shah
  • Status changed from New to Closed

Everything is done in this task except for the package.html stuff. That has been moved to its own task #1948. This task is done.

#10 Updated by Greg Shah over 7 years ago

  • Target version deleted (Milestone 2)

Also available in: Atom PDF