I have large set of contents for the user. For a different user I would like to show different contents. For this I would like to produce different output by showing and not showing some of the contents (say chapters sections subsection) of the document.
My Idea is: While writing chapter/section I declare it to enable showing to a specific user by setting argument to true or false. For example,
if (user1 == true) then it should be there in
user1.pdf
More specifically, something like:
Macro is: \chapter <chapterName1> [bool arg1][bool arg2][bool arg3]
\chapter <chapterName1> [user1==true][user2==false][user3==false]
\chapter <chapterName2> [user1==true][user2==true][user3==false]
\section <sectionName1> [user1==true][user2==true][user3==true]
If I pass user1 and user3 as 'True', then my output should contain
command (ex) : \def\arg1=true, arg2=false, arg1=true \input{myfile}
chapterName1
sectionName1
How can I do this?
[]parameters following the chapter/section are the default allowabilities for that chap/sec. At the beginning of the file, or on the command line, you would like to specify the target users for this particular build. What I don't understand is, if user3 is true, he should not get chapterName1, and yet your example shows him getting it. Are you proposing a means to override the defaults? [Also, do you have a typo by mentioning arg1 twice, and arg3 not at all in your "command ex" line?] – Steven B. Segletes Apr 08 '13 at 15:02