You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 10, 2025. It is now read-only.
Repository navigation
This repository was archived by the owner on Sep 10, 2025. It is now read-only.
Putting together some decent examples, in #66, made me consider how other people might approach problems.
I tend to use wget for downloading binaries, for example. But these days curl is perhaps more common.
It might be nice to support this:
let download=""
let download="/usr/bin/curl" if exists(/usr/bin/curl)
let download="/usr/bin/wget" if exists(/usr/bin/wget)
fail { message => "Can't find download program", if empty(download)}
Of course there's the obvious argument "If you want to use wget just .. install it":
package { name => "wget", state => "installed", name => "wget:package" }
shell { name => "download" , require => "wget:package" }
Still supporting conditionals in rules and includes does mean that assignments are the odd one out ..
Activity
Allow assignments to be conditional.
72 conditional assign (#77)