Hi Rob!
>> echo -e "const compile_date=$(date +%Y%m%d) \nconst compile_time=$(date >> +%H%M%S)" | ~/JAL/jallib/compiler/jalv2 -include /dev/stdin $(find >> ~/JAL/jallib/include -type d \! -path '*.svn*' -printf '-s %p ') $* > > > Clever! But I'm not so much in favor of one-liners.. I prefer (better > understand) 'structured' scripts. So do I, but bash inliners are a great way to make people look stupid. Sorry for that :-D And, i do dislike temporary files if I can avoid them. That is why I did this pipe trick. The echo at the beginning outputs something like const compile_date=20130109 const compile_time=152817 this is passed to stdin of the compiler. The compiler, due to the parameter " -include /dev/stdin" reads this as its first include file, so the two lines become part of the program without existing as a file. >Question: which version of SubVersion are you using? I'm using 1.7.6 and have >only 1 directory '.svn' (with lots of subdirectories). That may have changed >from 1.6 to 1.7. It's 1.6.12, as I haven't upgraded ubuntu on my workstation for ages ;-) There is a .svn-subdirectory in every directory. >How do you include compile_date and _time in your jal program? Oh, for now it's just print_string(serial,"Compiled on ") print_dword_dec(serial,compile_date) print_string(serial," at ") print_dword_dec(serial,compile_time) Greets, Kiste -- You received this message because you are subscribed to the Google Groups "jallib" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/jallib?hl=en.
