Skip to content

Implements ipinfo tool is_valid#170

Merged
UmanShahzad merged 9 commits intomasterfrom
haris/BE-2215
Sep 7, 2023
Merged

Implements ipinfo tool is_valid#170
UmanShahzad merged 9 commits intomasterfrom
haris/BE-2215

Conversation

@Harisabdullah
Copy link
Copy Markdown
Contributor

No description provided.

@linear
Copy link
Copy Markdown

linear bot commented Aug 29, 2023

BE-2215 CLI: ipinfo tool valid

Implement `ipinfo tool valid`` function of netIP.

Copy link
Copy Markdown
Contributor

@UmanShahzad UmanShahzad left a comment

Choose a reason for hiding this comment

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

Needs to follow subcmd naming style as used in others (snake case not pascal / camel case).

Comment thread ipinfo/cmd_tool.go Outdated
Comment thread ipinfo/cmd_tool.go Outdated
"next": completionsToolNext,
"prev": completionsToolPrev,
"is_v4": completionsToolIsV4,
"isValid": completionsToolIsValid,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Should be is_valid.

Comment thread ipinfo/cmd_tool_isValid.go Outdated
`Usage: %s tool IsValid <ip>

Description:
reports whether the Addr is an initialized address (not the zero Addr).
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Same as above

Comment thread ipinfo/cmd_tool_isValid.go Outdated
Examples:
%[1]s IsValid "190.87.89.1"
%[1]s IsValid "2001:0db8:85a3:0000:0000:8a2e:0370:7334"
%[1]s IsValid "::"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Do provide an invalid example if not already

Comment thread lib/cmd_tool_valid.go Outdated
Harisabdullah and others added 4 commits August 30, 2023 15:18
Co-authored-by: Uman Shahzad <uman@ipinfo.io>
Co-authored-by: Uman Shahzad <uman@ipinfo.io>
@Harisabdullah Harisabdullah changed the title Implements ipinfo tool isValid Implements ipinfo tool is_valid Aug 30, 2023
Copy link
Copy Markdown
Contributor

@UmanShahzad UmanShahzad left a comment

Choose a reason for hiding this comment

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

One small fix

Comment thread ipinfo/cmd_tool_isValid.go Outdated
`Usage: %s tool is_valid <ip>

Description:
reports whether the ip address is an initialized address (not the zero Addr).
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I left a comment here as well to update this desc to match the short desc above

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Sure! I'll take care of it

@UmanShahzad UmanShahzad merged commit 7547c17 into master Sep 7, 2023
@UmanShahzad UmanShahzad deleted the haris/BE-2215 branch September 7, 2023 11:40
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