Skip to content

Add CLI argument --adapter [<NAME>] to allow immediately starting the capture from a given network interface - #643

Merged
GyulyVGC merged 5 commits into
mainfrom
cli-adapter
Nov 24, 2024
Merged

GyulyVGC merged 5 commits into
mainfrom
cli-adapter

Conversation

@GyulyVGC

@GyulyVGC GyulyVGC commented Nov 24, 2024 •

Copy link
Copy Markdown
Owner

This PR adds a new CLI argument --adapter [<NAME>] to allow immediately starting the capture from a network interface given its name.

If a name isn't passed to the --adapter flag, the capture will be started from the latest sniffed adapter, or the default adapter in case it's the very first launch of the app.
The same is done even in case the passed adapter name is invalid or not existing.

Since Sniffnet's CLI arguments are getting more complex, I decided to start using clap to parse them.

Fixes #636.

@GyulyVGC GyulyVGC added the enhancement New feature, request, or improvement label Nov 24, 2024
@GyulyVGC GyulyVGC added this to the v1.3.2 milestone Nov 24, 2024
@GyulyVGC GyulyVGC self-assigned this Nov 24, 2024

@GyulyVGC GyulyVGC left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

🚢

@GyulyVGC
GyulyVGC merged commit dd46f32 into main Nov 24, 2024
@GyulyVGC
GyulyVGC deleted the cli-adapter branch November 24, 2024 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature, request, or improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Start the monitoring given adapter name from CLI

1 participant