Hi Freddie,

A belated thanks for this tip.

I was able to get something working using this %<group> construct.  It's a 
bit hackish (in my particular case), since I ended up merely echoing the 
value of %<group>, which somehow caused Tup to behave as I wanted.  But I 
understand the difficulty with the underlying issue.

The %<group> feature (as a command flag) is not mentioned in the manual.  I 
think I have read everything in the docs (including journal.html!)---is 
there some documentation of how this works exactly?

Further to that... not being a C programmer myself, but being a great fan 
of Tup, is there some way that I can help with the project?


Thanks for all your help,
Gavin



On Friday, October 9, 2015 at 3:04:21 AM UTC-5, Freddie Chopin wrote:
>
> Hello! 
>
> There is an issue for this particular problem here: 
>
> https://github.com/gittup/tup/issues/214 
>
> However your example would work with groups: 
>
> > $ cat Tupfile 
> > 
> > : |> echo a > %o |> a.in <group> 
> > : |> echo 1 > %o |> a--1 <group> 
> > 
> > #: |> echo 2 > %o |> a--2 <group> 
> > 
> > : <group> |> cat %<group> > %o |> a.out 
> > 
> > $ tup init 
> > .tup repository initialized. 
> > $ tup 
> > [ tup ] [0.007s] Scanning filesystem... 
> > [ tup ] [0.014s] Reading in new environment variables... 
> > [ tup ] [0.021s] Parsing Tupfiles... 
> > 
> >  1) [0.001s] . 
> >  [ ] 100% 
> > 
> > [ tup ] [0.026s] No files to delete. 
> > [ tup ] [0.026s] Checking circular dependencies among groups... 
> > [ tup ] [0.026s] Generating .gitignore files... 
> > [ tup ] [0.034s] Executing Commands... 
> > 
> >  1) [0.001s] echo 1 > a--1 
> >  2) [0.001s] echo a > a.in 
> >  3) [0.001s] cat %<group> > a.out 
> >  [   ] 100% 
> > 
> > [ tup ] [0.043s] Updated. 
> > $ cat a.out 
> > a 
> > 1 
> > $ <edit the Tupfile, uncomment the third line> 
> > $ cat Tupfile 
> > 
> > : |> echo a > %o |> a.in <group> 
> > : |> echo 1 > %o |> a--1 <group> 
> > : |> echo 2 > %o |> a--2 <group> 
> > : 
> > : <group> |> cat %<group> > %o |> a.out 
> > 
> > $ tup 
> > [ tup ] [0.000s] Scanning filesystem... 
> > [ tup ] [0.006s] Reading in new environment variables... 
> > [ tup ] [0.006s] Parsing Tupfiles... 
> > 
> >  1) [0.001s] . 
> >  [ ] 100% 
> > 
> > [ tup ] [0.007s] No files to delete. 
> > [ tup ] [0.007s] Checking circular dependencies among groups... 
> > [ tup ] [0.007s] Generating .gitignore files... 
> > [ tup ] [0.013s] Executing Commands... 
> > 
> >  1) [0.001s] echo 2 > a--2 
> >  2) [0.001s] cat %<group> > a.out 
> >  [  ] 100% 
> > 
> > [ tup ] [0.022s] Updated. 
> > $ cat a.out 
> > a 
> > 1 
> > 2 
> > $ 
>
> This simple example would also work with {bins}. 
>
> Regards, 
> FCh 
>

-- 
-- 
tup-users mailing list
email: [email protected]
unsubscribe: [email protected]
options: http://groups.google.com/group/tup-users?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"tup-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to