README
======
First things first
------------------
Learn [Markdown](https://help.github.com/articles/github-flavored-markdown)! Then check out MDwiki's [quick start](http://dynalon.github.io/mdwiki/#!quickstart.md).
Whenever you feel stuck, go to [MDwiki's own site](http://mdwiki.info) for further information.
One Wiki Only? Fork It.
-----------------------
First off fork this repo and call it something like `<MyProject>-wiki`.
Multiple Wikis? Clone It.
-------------------------
In case would you like to create more than one wiki for the same GitHub user or organization, then forking won't cut it. At the moment of this writing GitHub won't allow you to fork a single repository multiple times for the same account.
There's a workaround to this, however on GitHub's web interface you won't see the sign that says "forked from" in your cloned repository.
Below instructions how to clone this repository using the CLI:
**First off, create a new (empty) repository on GitHub, then;**
```bash
git clone https://github.com/exalted/mdwiki-seed.git
cd mdwiki-seed
git remote add foobar <HTTPS/SSH Clone URL of the New Repository>
git push foobar gh-pages
```
Create a New Wiki
-----------------
It all begins by creating an initial file structure for any language that you would like to support. For example, if you're interested having a wiki in English, then you will duplicate `ll_CC` folder and rename your copy to `en`. (For a complete list of languages [`ll`] and country codes [`CC`] [see here](http://msdn.microsoft.com/en-us/library/ee825488).)
`ll_CC` is a starter template folder which you shouldn't ever edit directly, since you may loose your changes when MDwiki gets updated later.
> If you want to have your wiki in more than one language, then you duplicate `ll_CC` as many times as necessary and rename each copy with the appropriate language and country code. (Country code is optional and it is only useful if you want to distinguish, for instance, American English from British English, such as: `en_US` and `en_GB`.)
Getting Started
---------------
_You should have a language wiki folder by now, if not, go back and read above to create one._
Suppose your first wiki is going to be in English, hence you must have a folder called `en`, as previously described.
1. Open `index.html` file with your favorite plain text editor (the one that is at the same level where `ll_CC` and your language folder is located, **NOT the one inside your language folder**)
1. Find where it says "Override `ll_CC` below with your default language and country code"
1. Change refresh meta tag from `url=ll_CC/` to `url=en/` **(trailing `/` is very important)**
Structure
---------
_All file references here are relative to their respective language folder._
| Name | Type | Description |
| :--- | :--- | :--- |
| `index.md` | File | Starting point (a.k.a. "home page") for your wiki. **Note this is not the `index.html`, but `index.md`**! |
| `navigation.md` | File | Various settings of your wiki (e.g., name of your wiki, items in the navigation bar at the top, etc.) |
| `config.json` | File | If you don't know what this is for, don’t touch it. |
| `pages` | Folder | Ideally, inside this folder, you create one `*.md` file for every page inside your wiki (e.g., `foo.md`, `much-longer-names-are-also-okay.md`, etc.) You can also create as many subfolders as you need, just remember to link them accordingly. |
| `uploads` | Folder | An example folder structure where you could put other files. **Although it is best to host your files somewhere else, like Dropbox, or a CDN, etc.** |
Best Practices
--------------
### Relative URLs
Instead of using absolute URLs when linking one wiki page to another, use relative URLs.
For instance if `en/pages/foo.md` page had to link to `en/pages/bar.md`, it is enough to just add `[Click here](bar.md)` in your markdown.
### Don't Host Your Uploads in Git(Hub)
Instead of hosting your uploads inside the `uploads` folder, consider using Dropbox, Google Drive, or a CDN.
### Add References to Uploads
**Whenever you can, avoid hosting your uploads using Git(Hub).**
If you _must_ add references to files hosted inside the `uploads` folder here's how to do it, for instance: `![Image Title](uploads/images/foo.png)`. Add that in your markdown and you're good to go.
How to Preview
==============
In order to preview your changes locally, prior to publishing online, you may need to take some actions. Below some starting points for each operating system, also check out MDwiki's [frequently asked questions](http://dynalon.github.io/mdwiki/#!faq.md) section for some ideas.
Mac OS
------
The easiest way to serve up static sites on a Mac is to use [Anvil](http://anvilformac.com). Go ahead and download it from their website, install and add a site using the status bar icon: simply select the folder where your wiki is located on your Mac.
If you don't want to download any apps, you can use the Terminal on your Mac and Python. To do this, go to your site folder in the Terminal app and type `python -m SimpleHTTPServer 8000`. This will start running a local server which you can navigate to by typing the URL `localhost:8000` in any web browser.
Windows
-------
You can use [Fenix](http://fenixwebserver.com) to host a static site on windows. Fenix also comes with lots of advanced functionality that you might not use. Fenix can also run on a Mac.
Linux
-----
You can use [Prax](http://ysbaddaden.github.io/prax/). Prax is a pure ruby alternative to Pow!! that runs on GNU/Linux.
For Developers
==============
You don't need to read below here or do anything at all if you're only interested creating your own wiki. This section is for developers or maintainers of this repository.
Update MDwiki
-------------
> Current version: [0.6.2](http://git.io/HBH5Wg).
1. Go to https://github.com/Dynalon/mdwiki/releases/latest
1. Click on the green button on that page to download the latest release
1. Extract the contents of the archive file
1. Copy `mdwiki-slim.html` file from the extracted files onto `ll_CC/index.html` file in this repository by renaming, thus overriding `index.html`
1. Update the version information above
1. Commit and push your changes
You can now delete any files downloaded previously, if you want to.
没有合适的资源?快使用搜索试试~ 我知道了~
mdwiki 项目模板代码
共16个文件
gitkeep:6个
md:5个
html:2个
5星 · 超过95%的资源 需积分: 18 44 下载量 77 浏览量
2016-12-30
17:56:28
上传
评论
收藏 43KB ZIP 举报
温馨提示
可用于搭建 mdwiki 项目架构,mdwiki 是基于 markdown 的 wiki 系统。里面有一些基础文件,可在此基础上进行扩展。
资源推荐
资源详情
资源评论
收起资源包目录
mdwiki-seed-gh-pages.zip (16个子文件)
mdwiki-seed-gh-pages
index.html 272B
.gitignore 2KB
README.md 6KB
ll_CC
navigation.md 1KB
index.html 83KB
pages
uploads
pdf
.gitkeep 0B
images
.gitkeep 0B
presentations
.gitkeep 0B
music
.gitkeep 0B
documents
.gitkeep 0B
movies
.gitkeep 0B
about.md 2KB
download.md 1KB
index.md 922B
config.json 192B
.gitattributes 1KB
共 16 条
- 1
资源评论
- 岚樱时vivi2020-05-28docker wiki 安装这个插件之后,本身的富文本编辑器可以支持markdown语法了,亲测可用。
DeniroLee
- 粉丝: 1235
- 资源: 8
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功