Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom command to hide passwords under notes does not work in 8.0.0 #2725

Open
setedivento opened this issue May 16, 2024 · 0 comments
Open
Labels

Comments

@setedivento
Copy link

setedivento commented May 16, 2024

Context
what I need to do is to make CopyQ, when the main window is displayed, hide the text of those clipboard items that have an associated note – provided they are placed under a specific tab.
Let's say the tab is called "auths" and I have all my stored passwords in there: what I want to achieve is being able to copy the passwords as regular text as usual, but to hide them when, suppose, I have to share the screen during work-calls.

Bug description
I have created a custom command to achieve what I want, and that has always worked in past versions of CopyQ: while now, whether you install the same version of CopyQ (8.0.0) on Windows 10 or Windows 11, it doesn't make a difference, and it works only in a particular case, but not the main desidered one.
The command's script is conceived to work in Display mode, so it only affects how copy items are shown, and not their clipboard content when they are copy-pasted.

To look at the script's details, please refer to the following images.
1 script code
2 script cfg

To Reproduce
please add a new Command with this code:

copyq:
var notes = str(data(mimeItemNotes))
if (notes) {
  setData(mimeText, "")
}

and configure the Advanced options like in the image above, creating a new tab and setting it as the target of the Command.
Now in the dedicated tab you have created, add a new copy item, and then add a note to that: let's call this item "item with a note".

Expected behavior
The item with a note, when the main window of the program in activated, should display the note text only, and not its original source text; but then when the item is pasted, CopyQ should paste the source text as usual.

Screenshots
this is the result of the Command when the main program window is dispayed and it works
notes_working
this is the result of the Command when the main program window is dispayed and it doesn't work
notes_not_working

Version, OS and Environment

  • Application Version: 8.0.0
  • OS: Windows 10, Windows 11
  • Desktop environment, normal explorer.exe shell

Additional notes
the Command works when you modify the notes of an item; but the change is not persistent, and all the items return to their previous state when one exits and opens the program again.

Thanks so much for fixing this!

@setedivento setedivento changed the title A command to hide passwords under notes does not work in Windows 11 Custom command to hide passwords under notes does not work in 8.0.0 May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant