To receive notifications about scheduled maintenance, please subscribe to the mailing-list gitlab-operations@sympa.ethz.ch. You can subscribe to the mailing-list at https://sympa.ethz.ch

Commit bb08f715 authored by vermeul's avatar vermeul
Browse files

Merge branch 'master' of https://gitlab.ethz.ch/vermeul/YATA

parents 85d3676c 5ffefa79
...@@ -42,6 +42,7 @@ Annotations usually contain comments and may be categorised (Categories: see bel ...@@ -42,6 +42,7 @@ Annotations usually contain comments and may be categorised (Categories: see bel
{{#annot: comment | category1, category2}} # annotation with more than one category {{#annot: comment | category1, category2}} # annotation with more than one category
{{#annot: comment | category | some_id}} # an id is used to identify the proper end of the annotation when nesting. Annotation end must contain the same id: `{{#annotend: some_id}}` {{#annot: comment | category | some_id}} # an id is used to identify the proper end of the annotation when nesting. Annotation end must contain the same id: `{{#annotend: some_id}}`
{{#annot: | category}} # just specifiying the category a text belongs to, with no comment {{#annot: | category}} # just specifiying the category a text belongs to, with no comment
{{#annot: | #category_hashtag }} # the hashtag is a quicker way to access annotation categories that have large names
{{#annot: comment | | some_id}} # nested annotation with an id to identify its ending, without any category {{#annot: comment | | some_id}} # nested annotation with an id to identify its ending, without any category
{{#annotend: id}} # End-of-Annotation-Tag. The id must be present if the opening tag has one. {{#annotend: id}} # End-of-Annotation-Tag. The id must be present if the opening tag has one.
{{annotend}} {{#annotend}} # some syntax sugar in case you forget the colon or the hash symbol {{annotend}} {{#annotend}} # some syntax sugar in case you forget the colon or the hash symbol
...@@ -95,6 +96,7 @@ See the [SMW concepts](https://www.semantic-mediawiki.org/wiki/Help:Concepts) ...@@ -95,6 +96,7 @@ See the [SMW concepts](https://www.semantic-mediawiki.org/wiki/Help:Concepts)
``` ```
[[category: category_name1 ]] # this category (and all categories below it) [[category: category_name1 ]] # this category (and all categories below it)
[[category: category_name1, category_name2 ]] # category_name1 OR category_name2 [[category: category_name1, category_name2 ]] # category_name1 OR category_name2
[[category: #category_tag1, #category_tag2 ]] # category hashtags can be used as well
[[category: category_name1 ]] # every line is AND'ed, so these two lines mean: [[category: category_name1 ]] # every line is AND'ed, so these two lines mean:
[[category: category_name2 ]] # category_name1 AND category_name2 [[category: category_name2 ]] # category_name1 AND category_name2
...@@ -114,14 +116,14 @@ _ match any single character ...@@ -114,14 +116,14 @@ _ match any single character
``` ```
{{#annotask: {{#annotask:
[[category: parent_category1/child_category1 ]] [[category: parent_category1/child_category1 ]]
[[category!: parent_category2/child_category2 ]] [[category!: #some_unwanted_category ]]
[[comment: %a part of my comment% ]] [[comment: %a part of my comment% ]]
[[wiki_text: %this is somewhere in my text%]] [[wiki_text: %this is somewhere in my text%]]
}} }}
``` ```
Find all annotations Find all annotations
* which belong to category `category parent_category1/child_category1` * which belong to category `category parent_category1/child_category1`
* but not to category `parent_category2/child_category2` * but not to category `#some_unwanted_category`
* and contain the comment `a part of my comment` * and contain the comment `a part of my comment`
* and contain `this is somewhere in my text` in the extracted annotation * and contain `this is somewhere in my text` in the extracted annotation
...@@ -135,7 +137,6 @@ The result is a sortable table containing the following data: ...@@ -135,7 +137,6 @@ The result is a sortable table containing the following data:
Because Pages can be long, the link contains an anchor (bookmark) and thus the result will appear immediately at the top of the page. Because Pages can be long, the link contains an anchor (bookmark) and thus the result will appear immediately at the top of the page.
To achieve this, all annotations automatically get a bookmark generated which will result in a unique `id` within that page. To achieve this, all annotations automatically get a bookmark generated which will result in a unique `id` within that page.
<<<<<<< Updated upstream
## Annotation Categories ## Annotation Categories
...@@ -175,8 +176,8 @@ Put this on any WikiPage and it will list existing categories: ...@@ -175,8 +176,8 @@ Put this on any WikiPage and it will list existing categories:
To add a new category into the categories table, we simply add one of the following anywhere in a Wiki Page: To add a new category into the categories table, we simply add one of the following anywhere in a Wiki Page:
``` ```
{{#annotcat: add | name='new top category', description='some meaningful comments', parent='grandparent_category/parent_category' }} {{#annotcat: add | name='new top category', hashtag='#my_top_cat', description='some meaningful comments', parent='grandparent_category/parent_category' }}
{{#annotcat: add | name='new top category', description='some meaningful comments', parent='parent_category' }} # add to an existing top category {{#annotcat: add | name='new top category', hashtag='#my_top_cat', description='some meaningful comments', parent='parent_category' }} # add to an existing top category
``` ```
Only the name argument is mandatory, everything else is optional. If you don't specify a parent category, a new top category will be created. Only the name argument is mandatory, everything else is optional. If you don't specify a parent category, a new top category will be created.
...@@ -188,10 +189,13 @@ To update a category, add something like this to any Wiki Page: ...@@ -188,10 +189,13 @@ To update a category, add something like this to any Wiki Page:
``` ```
# update everything # update everything
{{#annotcat: up | kat_parent/kat_child | name='new category name', description='new description', parent='grandparent_category/parent_category' }} {{#annotcat: up | kat_parent/kat_child | name='new category name', description='new description', parent='grandparent_category/parent_category' }}
{{#annotcat: up | #category_hashtag | name='new category name', description='new description', parent='#parent_category_hashtag ' }}
# make a category becoming a top category # make a category becoming a top category
{{#annotcat: up | kat_parent/kat_child | parent=}} {{#annotcat: up | kat_parent/kat_child | parent=}}
{{#annotcat: up | #category_hashtag | parent=}}
# remove description # remove description
{{#annotcat: up | kat_parent/kat_child | description=}} {{#annotcat: up | kat_parent/kat_child | description=}}
{{#annotcat: up | #category_hashtag | description=}}
``` ```
If you do not want to update certain fields, just omit them. If you want to remove the parent or deleting the description, just leave the value empty. If you do not want to update certain fields, just omit them. If you want to remove the parent or deleting the description, just leave the value empty.
...@@ -202,6 +206,7 @@ To delete a category, add this to any Wiki Page: ...@@ -202,6 +206,7 @@ To delete a category, add this to any Wiki Page:
``` ```
{{#annotcat: del | parent_cat_name/cat_name }} {{#annotcat: del | parent_cat_name/cat_name }}
{{#annotcat: del | #category_hashtag }}
{{#annotcat: del | cat_name }} # if the category is a top category (no parent) {{#annotcat: del | cat_name }} # if the category is a top category (no parent)
``` ```
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment