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

Hello-World #10

Open
HazardJ opened this issue Dec 11, 2015 · 2 comments
Open

Hello-World #10

HazardJ opened this issue Dec 11, 2015 · 2 comments

Comments

@HazardJ
Copy link
Member

HazardJ commented Dec 11, 2015

Eve asked, Marc has long militated for:

Cmacc for Dummies

Learning the system is easy because there is not a lot you can do. Just a few things. Cmacc mostly just ties together stuff you already do (or should do) - make files, reference files, edit a page. Much of this can be done via a GitHub account, and that is the preferred way to collaborate on helping us create legal standards. Soon we hope to have a browser-based "parser," which would mean that you would never have to do more than use GitHub or your own choice of hosting for files, for instance Mediawiki. And soon we hope that transacting platforms will include a parser in their interface so that you never have to leave your phone. In the meantime, however, to get full benefit, you have to do an "install." If you are a techie, this can be one minute (clone github.com/commonaccord/Cmacc-Org to a place with LAMP capabilities). Otherwise, you may have to find a techie or brave the installation of https://www.mamp.info/en/ and figuring out how to clone on GitHub. We have some help for you on that. How to Deploy Locally

We assume that you have a local install.

Make a file:

Use a text editor. Save a file where you want in /Doc/. /Doc/ has all the Cmacc files. It is recommended, but not necessary, to end the file name with ".md". You can continue to edit in the text editor or navigate to the page in your browser and click "Edit". If you are Eve and want to play go to http://www.commonaccord.org/index.php?action=source&file=S/Sandbox/Eve/1_v0.md

Make a "document":

Type the following:

Model.Root={HW}

Save (in your text editor) and then click "Document". You'll see {HW} in red.

Go back to editing (click Edit) and add a line (either above or below the previous one, but it is good practice to add above.

HW={H} {W}

Save and click Document. Now you have {H} and {W} in red, because {HW} was expanded by HW=.

Now click Edit and Complete - you'll see that H= and W= are there, waiting for you to type "H=Hello" and "W=World" (without the quotes). Save and click Document. Hello World

Now click Edit and add at the top(priority counts) "H=Bonjour". Leave the H=Hello in the document. Click Save then Document. "Bonjour World".

You are halfway there.

Next, add a line at the top:

=[Z/ol/5]

"Comment out" the Model.Root={HW} by changing its name to, say, /Model.Root={HW}. Click Save, Document. You should see an outline of five points, nearly all of it in red.

Next click on Edit and Complete:

You will see that the only thing you are offered is "Ti=". Complete it with Ti={HW}. But also write 1.Ti=English and 1.sec=Hello {W}. Save, Document. You should have a section with a title "Bonjour World" and a section 1 titled "English" with content of "Hello World". (You will also notice that each of the subsections defaults to the same title. This is because of "de-prefixing" - a very useful feature, often extremely natural seeming, but sometimes also veodd, like here.)

Click edit, and add (either above, or below your last work) 2.Ti=French, 2.sec={H} Monde. Etc.

You have done overriding, both in the file and vis-a-vis the =[Z/ol/5].

Now, add an intro to the paragraph sections. In Edit, add:

0.sec=Here's how you say hello in different parts of the world:

Save, Document. You'll see that there is now an intro. (It defaults to no intro because deep in [Z/ol/5] is an 0.sec=, which presents as nothing. (HTML is oddly sweet about these things.)

You can do the same for an extro -

90.sec=That's all for now.

Now let's do "prefixing." Let's say you want to do the variations on English - UK, US, Aussie, etc. In Edit, type:

1.=[Z/ol/3]

and

1.1.Ti=UK

1.1.sec=Top of the marnin'

1.2.Ti=Australian

1.2.sec=G'day

1.3.Ti=US

1.3.sec=Howdy

1.4.Ti=Geek

now - CHANGE the key on 1.sec=Hello {World} to 1.4.sec=Hello {W}

(Notice that the position in the file doesn't matter, except that if there are two (or more) keys with the same name, the FIRST one is what counts.)

LMK - done blind.

@xmlgrrl
Copy link
Collaborator

xmlgrrl commented Dec 11, 2015

I'm missing knowing a few things (and, also, I can't seem to edit the sample doc). I get that {} does replacement, / does commenting, and . is allowed in key names of replacement values. What is the magic of =[] at the top? What are the other character/line order constraints and allowances? Thanks!

@HazardJ
Copy link
Member Author

HazardJ commented Dec 11, 2015

/ comments only bz it changes the name. Could use ! or - or Old-.

[Means_File_Name]
Which is as if we copied the content of that file at the bottom or our
page.
On Dec 11, 2015 16:30, "Eve Maler" [email protected] wrote:

I'm missing knowing a few things (and, also, I can't seem to edit the
sample doc). I get that {} does replacement, / does commenting, and . is
allowed in key names of replacement values. What is the magic of =[] at the
top? What are the other character/line order constraints and allowances?
Thanks!


Reply to this email directly or view it on GitHub
#10 (comment)
.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants