README.md in visualize_packwerk-0.0.5 vs README.md in visualize_packwerk-0.0.6

- old
+ new

@@ -1,32 +1,27 @@ # visualize_packwerk This gem contains rake tasks to help visualize relationships between packwerk packs. # Usage -## Building a package graph for a selection of packages (owned by 5 teams max) +## Building a package graph for a selection of packages +```ruby +# Select the packs you want to include +selected_packs = ParsePackwerk.all +selected_packs = ParsePackwerk.all.select{|p| ['packs/my_pack_1', 'packs/my_pack_2'].include?(p.name) } +selected_packs = ParsePackwerk.all.select{|p| ['Team 1', 'Team 2'].include?(CodeOwnership.for_package(p)&.name) } +VisualizePackwerk.package_graph!(selected_packs) ``` -bin/rails visualize_packwerk:package_relationships['packs/pack1','packs/pack2'] -``` -# Building a package graph for specific teams (5 teams max) +# Building a team graph for specific teams ``` -bin/rails visualize_packwerk:package_relationships_for_teams['Team1','Team2'] +# Select the teams you want to include +selected_teams = CodeTeams.all +selected_teams = CodeTeams.all.select{ ... } +VisualizePackwerk.team_graph!(selected_teams) ``` -# Building a package graph for all packages (this is slow and produces a huge file) -``` -bin/rails visualize_packwerk:package_relationships -``` - -# Building a TEAM graph for specific teams -``` -bin/rails visualize_packwerk:team_relationships['Team1','Team2'] -``` - -# Building a TEAM graph for all teams (this is slow and produces a huge file) -``` -bin/rails visualize_packwerk:team_relationships -``` +## bin/packs +For simpler use, use `bin/packs` in `use_packwerk` (https://github.com/rubyatscale/use_packwerk) # Want to change something or add a feature? Submit a PR or post an issue!