Skip to content

Instantly share code, notes, and snippets.

@omar-yassin
Last active April 13, 2016 04:09
Show Gist options
  • Save omar-yassin/0efe814cf29be33dfe1772b5e702e0be to your computer and use it in GitHub Desktop.
Save omar-yassin/0efe814cf29be33dfe1772b5e702e0be to your computer and use it in GitHub Desktop.
Powershell: pretty way to compare if string contains multiple strings
$failed_status_types = 'CREATE_FAILED', 'DELETE_FAILED', 'ROLLBACK_FAILED', 'UPDATE_ROLLBACK_FAILED'
if ($failed_status_types -match "some_string" ) { "si" }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment