Etymology
Today it means: At one's discretion. Full definition →
From discretionary + -ly.
Etymology from Wiktionary, CC BY-SA 4.0.