Skip to content

Conversation

@ConniBug
Copy link

@ConniBug ConniBug commented Nov 3, 2020

Added the abilty to parse custom command line args

Added the comand line arg -t

You can now run
./main -t 1000

and it will wait 1000ms (1 second) after each check on the dir

@ConniBug ConniBug changed the title Update main.rs Add command line args Nov 3, 2020
@bobbbay
Copy link
Contributor

bobbbay commented Nov 3, 2020

@ConniTheKiwi Cool! Although, I had originally asked for -t 1000 to run the script for 1 second, not have timing between the script.

@ConniBug
Copy link
Author

ConniBug commented Nov 3, 2020

Ah i seem to have missunderstood, shouldnt be to hard to implement a timer

@bobbbay
Copy link
Contributor

bobbbay commented Nov 3, 2020

fixes #5

@bobbbay bobbbay linked an issue Nov 3, 2020 that may be closed by this pull request
-t <time ms> 
will run only for this set amount of time
@ConniBug
Copy link
Author

ConniBug commented Nov 5, 2020

I believe this is what you requested?

-m <sub dir name>
-m os
checks /semc/logger/os
Copy link
Contributor

@bobbbay bobbbay left a comment

Choose a reason for hiding this comment

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

I've added some generic code reviews - let's see how much this one helps! Cheers 😉

@ConniBug
Copy link
Author

ConniBug commented Nov 5, 2020

Yeh i totally agree with what you have said in this review!,
i dont know a lot about the rust language btw so i had to google a few things to be able to implement them so that why some of the var names are terrible. ill fix it up based on your review

Made error messages more appropriate and understandable
@ConniBug
Copy link
Author

ConniBug commented Nov 5, 2020

Ill resolve the switch issue later on as im on mobile currently lol

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.

Allow command line arguments

2 participants