Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement linksmith inventory and linksmith output-formats #4

Merged
merged 1 commit into from
Apr 1, 2024

Conversation

amotl
Copy link
Contributor

@amotl amotl commented Apr 1, 2024

About

From the Linksmith RFC,
a little bit of both.

To be continued.

Details

Under the hood, many output formats are heavily based on what sphobjinv provides. Thanks a stack, @bskinn!

Copy link

codecov bot commented Apr 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (b09120a) to head (d77b191).

❗ Current head d77b191 differs from pull request most recent head cdf8399. Consider uploading reports for the commit cdf8399 to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##              main        #4    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files            1         8     +7     
  Lines            2       248   +246     
==========================================
+ Hits             2       248   +246     
Flag Coverage Δ
unittests 100.00% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@amotl amotl force-pushed the first-working branch 3 times, most recently from d77b191 to f9f6456 Compare April 1, 2024 21:17
@amotl amotl merged commit 5ea8867 into main Apr 1, 2024
3 checks passed
@amotl amotl deleted the first-working branch April 1, 2024 21:20
print(self.soi.json_dict())

def to_yaml(self):
logger.warning("There is certainly a better way to present an inventory in YAML format")
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check out bskinn/sphobjinv#283 -- @machow proposed a better JSON output format that might(?) make for more attractive YAML.

I need to actually implement that...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much. I knew you would have excellent suggestions about it. 💯

I merged this PR early, to get something working into main before going afk, but that does not mean I will not consider any other suggestions here, also in retrospective. Thanks!

@amotl
Copy link
Contributor Author

amotl commented Apr 1, 2024

Coming from our needs at CrateDB, for multi-project use, this incantation implements the best of DWIM we can have for now. Others may find this viable as well.

linksmith inventory \
  https://github.com/crate/crate-docs/raw/main/registry/sphinx-inventories.txt \
  --format=html+table > crate-sphinx-overview.html

open crate-sphinx-overview.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants