topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Thursday December 12, 2024, 9:22 pm
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: [feature request] specify the result of an alias with a text file  (Read 5666 times)

nitrix-ud

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 560
    • View Profile
    • Donate to Member
Hi,

it would be great if one could specify the result of an alias in a text file :

farr.png

it would allow people to create dynamic aliases...

practical example :

i have 100 projects...
i have code snippets, urls, texts, ... for all my projects
all those snippets are stored in 100 folders (1 project = 1 folder)

i'd like to use the same alias (an alias to copy the snippets into the clipboard...) for all my projects
since i already have a global project manager (global meaning system-wide)
i'd like to choose the current project then use the alias to paste the snippets BUT only the snippets of that particular project

to do that now i can (each time i change the current project) :
1) change the path of my dosearch command directly in the FARR alias xml file ... (i don't like that)
2) rename the snippet folder of the current project so that it matches the path in the alias... (or copy the snippets in the folder...)
hope you get the idea...

what i'd like to do :
change the content of the text file... much like 1)

benefits :
  • it does not interfere with FARR
  • easier to do

other example :
it's very easy to create an autohotkey script to add a line into a text file
let's say to save urls...
select an url, press the hotkey
then invoke FARR with the appropriate alias, there is your saved url !

Bonus !
there are many uses for this feature, i also suggest that one could specify multiple files in the result list
or even better mix files and actual results...
for example :
Google | http://google.com
file = c:/myfav.txt
Yahoo | http://yahoo.com
file = c:/myfav2.txt
file = c:/otherthings.txt

« Last Edit: November 28, 2007, 03:07 PM by nitrix-ud »

nitrix-ud

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 560
    • View Profile
    • Donate to Member
Re: [feature request] specify the result of an alias with a text file
« Reply #1 on: December 03, 2007, 06:44 AM »
@mouser,

i'd really like to know your views on that request :-[ ?

thanks in advance
Cheers, Keep up the good work
Nitrix

nitrix-ud

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 560
    • View Profile
    • Donate to Member
Re: [feature request] specify the result of an alias with a text file
« Reply #2 on: December 14, 2007, 04:27 PM »
i tried modifying xml FARR files, unfortunately, if you change those files they are not refreshed until you go inside FARR options  :huh:
which means dynamic aliases are not possible for the moment

any idea ?

nitrix-ud

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 560
    • View Profile
    • Donate to Member
Re: [feature request] specify the result of an alias with a text file
« Reply #3 on: December 14, 2007, 04:40 PM »
i'm also trying :

^sp (.*) (.*)
Snippets Projets $$1 | dosearch c:\_snippets\txt_snippets_projets\$$1\ +open_snippets -alias -.ini +. $$2

where $$1 would be the project number...
and $$2 the search

but i did not manage to make that one work either
if i type :
c:\_snippets\txt_snippets_projets\someNumber\ +open_snippets -alias -.ini +. keyword
it works...
 :huh:

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 40,914
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Read more about this member.
    • Donate to Member
Re: [feature request] specify the result of an alias with a text file
« Reply #4 on: December 14, 2007, 04:45 PM »
when you say you didnt manage to make it work, can you elaborate?

nitrix-ud

  • Charter Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 560
    • View Profile
    • Donate to Member
Re: [feature request] specify the result of an alias with a text file
« Reply #5 on: December 14, 2007, 05:07 PM »
sorry i did not elaborate a lot since i was a bit puzzled...

well i guess dosearch has a strange behavior:

now i'm trying the following:
^sp ((?:[^-]|-(?!-))*)(?:\s*--\s*(.*))?()
Snippets Projets $$1 | dosearch c:\_snippets\txt_snippets_projets\$$1\ +open_snippets -alias -.ini +. $$2

this alias should be triggered when typing :
sp 122 --keyword
in the alias edit box this says MATCH

but in real life :
sp 122 --keyword
does not work

BUT
sp 122--keyword
DOES

seems like dosearch does something strange


the more i think about it, the more i think there should be a way to create dynamic aliases
now i understand that my idea of specifying the result of an alias inside a text file is not enough...
we also need a way to refresh/reload those particular aliases