diff options
| author | ache <ache@ache.one> | 2026-03-08 03:16:54 +0100 |
|---|---|---|
| committer | ache <ache@ache.one> | 2026-03-08 03:16:54 +0100 |
| commit | cb976652e45fb195cac4296463af9d4e63911777 (patch) | |
| tree | 5d6c2a68fa7802294f4221d3768802dac08d6790 /src | |
| parent | fix: Prints error messages to stderr (diff) | |
feat: Quickly set address with @🪵
Diffstat (limited to 'src')
| -rw-r--r-- | src/lolbin/cli.py | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/src/lolbin/cli.py b/src/lolbin/cli.py index f976e54..49b3b2b 100644 --- a/src/lolbin/cli.py +++ b/src/lolbin/cli.py @@ -459,7 +459,21 @@ def app(): case name: if paste_name is None: - paste_name = name + if name.startswith("@"): + if name.startswith("@@"): + paste_name = name[1:] + else: + if not replace_address: + replace_address = True + if "address" in config: + # NOTE: Otherwise the token can't be correct + config["bearer_token"] = None + + config["address"] = name[1:] + else: + paste_name = name + else: + paste_name = name else: print( f"Ambiguous paste name. Aborting. {name} or {paste_name}", |