glanceapp / glanceapp/glance

Support multiple query values for search bangs

Open
#898 0 comments 0 reactions 0 assignees View on GitHub
feature request
Dominant language
Go
Stars
37.1k
Forks
1.5k
Avg merge
1h 11m
Merged PRs (30d)
1

Description

### Description

Currently, search bangs in `glance` accept a single query, which is substituted into the URL as `{QUERY}`. Some services, however, require multiple pieces of information from the query such as source and target languages for translation.

The goal of this feature is to allow a single bang shortcut to parse multiple values from the user input and map them into the URL as needed. This would make search bangs more flexible and powerful, enabling structured queries without requiring separate shortcuts for each variation.

Example: Google Translate

```yaml
- title: Google Translate
shortcut: "!tl"
url: "https://translate.google.com/?sl={QUERY}&tl={QUERY}&text={QUERY}&op=translate"
```

I’ll be working on this feature and would appreciate any feedback along the way.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by tracing how search bangs currently substitute {QUERY} in glance and compare that behavior with the Google Translate example. Define how multiple input values should be parsed and mapped to repeated placeholders, then verify the resulting shortcut URL.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.