-
Notifications
You must be signed in to change notification settings - Fork 46
feat: initialize documentation directory #610
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
Conversation
f200d2f
to
caf25c0
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, left some optional suggestions ;)
@@ -1,6 +1,6 @@ | |||
[tool.poetry] | |||
name = "rai_whoami" | |||
version = "0.0.1" | |||
version = "0.0.5" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why bump by 4 numbers?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Syncing with pypi. We are doing manual build & publish, which in the nearest future should be done automatically with auto version bump.
def initialize_docs_directory(args: argparse.Namespace) -> None: | ||
documentation_dir = Path(args.documentation_dir) | ||
if os.path.exists(documentation_dir): | ||
print( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. < 8000 a class="Link--inTextBlock" href="https://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment" aria-label="Learn more about hiding disruptive comments">Learn more.
logging?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought about it, decided to go with the simples option for such scripts.
parser = argparse.ArgumentParser() | ||
parser.add_argument("documentation_dir", type=Path) | ||
args = parser.parse_args() | ||
initialize_docs_directory(args) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
initialize_docs_directory(args) | |
initialize_docs_directory(**vars(args)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Never seen that, I will keep the same style as other script files.
@boczekbartek your proficiency with pathlib is nothing short of exquisite <3. |
Co-authored-by: Bartek Boczek <bartlomiej.boczek@robotec.ai>
Review and Merge after #609
Purpose
Reducing manual effort needed to start with rai-whoami
Proposed Changes
Provided convenience script for setting up required documentation structure.
Issues
N/A
Testing
Used the script.
remember to
pip install src/rai_whoami
as poetry does not install scripts.