Skip to content

qsreplace does not replace each parameter only once #9

@mikedesu

Description

@mikedesu

Perhaps I am misunderstanding how qsreplace is intended to work, but considering the description of the tool, I am receiving unexpected output. qsreplace is replacing every parameter value, not individually.

~ % cat urls.txt 
https://www.evildojo.com/index.php?q=search&name=darkmage
https://www.evildojo.com/index.php?q=search
https://www.evildojo.com/index.php
https://www.evildojo.com

~ % cat urls.txt | qsreplace d3v
https://www.evildojo.com/index.php?name=d3v&q=d3v
https://www.evildojo.com/index.php?q=d3v
https://www.evildojo.com/index.php
https://www.evildojo.com

The output I am expecting, however, is below:

https://www.evildojo.com/index.php?q=d3v
https://www.evildojo.com/index.php?q=d3v&name=darkmage
https://www.evildojo.com/index.php?q=search&name=d3v

I am releasing a tool to achieve this functionality, but I think it would be nice if this tool did it instead.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions