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

Add FormatEnumerationLimitOverride to config #72

Merged
merged 1 commit into from
Dec 14, 2017

Conversation

RamblingCookieMonster
Copy link
Contributor

Hiyo!

This simply adds a FormatEnumerationLimitOverride key to the bot configuration, with a default of -1

Ping me if you want to have any input on changes that you'd prefer (in direction or implementation) - cheers!

Description

Not sure if this is the direction you were looking for, or the right way to go about it if so. The saving current value / reverting in a final block, and using the global scope is based on this

  • We set this at bot.start(), revert to previous setting in a final block
  • We default to -1 given that output can't be explored out of the box - otherwise data can remain hidden and inaccessible

I added a parameter help bit to New-PoshBotConfiguration, but didn't update any example output from Get-PoshBotConfiguration (seems nice to have but superficial)

Related Issue

#47

Motivation and Context

See #47

How Has This Been Tested?

Manually tested by loading bot with no initial change to config; expected enumeration limit of -1 was correctly set
Manually tested by loading bot with config FormatEnumerationLimitOverride set to 6 (not default); expected limit of 6 was correctly set

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

* We set this at bot.start(), revert to previous setting in a final block
* We default to -1 given that output can't be explored out of the box - otherwise data can remain hidden and inaccessible
@RamblingCookieMonster RamblingCookieMonster changed the title WIP: Add FormatEnumerationLimitOverride to config Add FormatEnumerationLimitOverride to config Dec 14, 2017
@RamblingCookieMonster
Copy link
Contributor Author

Not sure why I called it a work in progress, this is ready for review if you're interested - I'm just assuming there might be more, or a better route given my limited knowledge of the codebase : )

@devblackops
Copy link
Member

Thanks @RamblingCookieMonster! I'll take a look.

@devblackops
Copy link
Member

devblackops commented Dec 14, 2017

LGTM! Thanks!

@devblackops devblackops added this to the v0.10.0 milestone Dec 14, 2017
@devblackops devblackops merged commit ef7484f into poshbotio:master Dec 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants