「過去ログ/nplll 構造に関するメモ」の版間の差分
ナビゲーションに移動
検索に移動
Ippei Suzuki (トーク | 投稿記録) ページの作成:「nplllの構造に関するドキュメント。 == 構造に関するガイドライン == * template_dirを除くSmartyフォルダ(config_dir、cache_dir、compile_…」 |
Ippei Suzuki (トーク | 投稿記録) |
||
| 39行目: | 39行目: | ||
*** MySmarty.class.php | *** MySmarty.class.php | ||
** util | ** util | ||
*** [ | *** [http://lastrss.oslab.net/ lastRss.php] | ||
*** [ | *** [http://phpflickr.com/ phpFlickr.php] | ||
*** MyParser.class.php → HTTP_Clientのラッパー | *** MyParser.class.php → HTTP_Clientのラッパー | ||
* local | * local | ||
| 56行目: | 56行目: | ||
** repos → レポジトリ格納用 | ** repos → レポジトリ格納用 | ||
* www | * www | ||
** | ** 69tracks → [http://www.69tracks.com/ 69tracks] <ref>deprecated</ref> | ||
** | ** backyard → [http://backyard.nplll.com 管理用] <ref>protected</ref> | ||
*** css | *** css | ||
*** images | *** images | ||
*** js | *** js | ||
*** lib | *** lib | ||
*** monologue → [ | *** monologue → [http://backyard.nplll.com/monologue monologue] | ||
*** pear → [ | *** pear → [http://backyard.nplll.com/pear PEAR GUI Interface] | ||
*** test → 各種テスト用 | *** test → 各種テスト用 | ||
*** templates | *** templates | ||
*** wiki → [ | *** wiki → [http://nplll.sakura.ne.jp/wiki/ Pukiwiki] | ||
*** php_info.php → [ | *** php_info.php → [http://backyard.nplll.com/php_info.php PHP INFO] | ||
** blog | ** blog | ||
*** mt4 → [ | *** mt4 → [http://nplll.sakura.ne.jp/blog/mt4/mt.cgi MovableType4] | ||
** freshreader → [ | ** freshreader → [http://fr.nplll.com FreshReader] | ||
** lab | ** lab | ||
*** diy → [[Do It Yourself Project | *** diy → [[Do It Yourself Project]] | ||
*** tumblr → [[Tumblr Services | *** tumblr → [[Tumblr Services]] | ||
** [ | ** [http://nplll.com nplll] | ||
*** code → [ | *** code → [http://nplll.com/code Code] | ||
*** config → HTMLで書き出されてしまうものはここに格納(シンボリックリンク含む) | *** config → HTMLで書き出されてしまうものはここに格納(シンボリックリンク含む) | ||
*** diary → [ | *** diary → [http://nplll.com/diary Diary] | ||
*** lib | *** lib | ||
*** moblog → [ | *** moblog → [http://nplll.com/moblog Moblog] | ||
*** mutter → [ | *** mutter → [http://nplll.com/mutter Mutter] | ||
*** src | *** src | ||
*** static → 静的ファイルはここに格納 | *** static → 静的ファイルはここに格納 | ||
*** templates | *** templates | ||
** suidou → [ | ** suidou → [http://suidou.d-archives.info/ 水曜どうでしょうD陣日記アーカイブ] | ||
*** archives | *** archives | ||
*** lib | *** lib | ||
*** templates | *** templates | ||
** | ** switchover → [http://www.switchover.info/ SWITCH-OVER] <ref>deprecated</ref> | ||
** | ** tooearly → [http://tooearly.net/ tooEarly] <ref>deprecated</ref> | ||
2019年5月2日 (木) 09:36時点における版
nplllの構造に関するドキュメント。
構造に関するガイドライン
- template_dirを除くSmartyフォルダ(config_dir、cache_dir、compile_dir)は$HOME/smarty直下のものを使用し新しく作らない
- lib、templates、css、jsの各ディレクトリはドメインごとに設置する(サブドメインも1ドメインとして扱う。以下同じ)
- ドメインを越えて使用するテンプレートファイルはSmartyフォルダ内のtemplatesディレクトリを使用する
- ディレクトリに関する定数は下記のルールに従う
- doc_root、lib_rootなどは$HOME直下のものを指す
- 各ドメインごとのディレクトリはdoc_dir、lib_dirなどとし、各ドメインごとに拡張して設定する
- 命名規則は下記のルールに従う
- class名は大文字で始まり単語ごとに大文字を使用する
- class名以外は小文字で始まり単語ごとに大文字を使用する
- ローマ字表記はヘボン式を採用
- 不必要な省略は行わない
- その他、黒田さんの書かれたJET SETにおけるPHPコーディング・ガイドライン(JET SET)に準拠する方向で。
現在のツリー構造
現在のツリー構造。
nplll
- backup → バックアップデータを格納
- batch → cron処理するプログラムなど。
- Diy1Nico
- DiyHatenaBookmark
- DiyRss
- Flickr
- cache → Smarty以外のキャッシュはここに格納
- lastRss
- config → アカウント情報など。XMLファイルを格納
- db → SQLiteなどデータベースファイルの格納
- lib → サーバ全体で使用する共通ライブラリ
- config
- MyConfig.class.php
- connect
- MyMysqlConnectionHandler.class.php
- smarty
- MySmarty.class.php
- util
- lastRss.php
- phpFlickr.php
- MyParser.class.php → HTTP_Clientのラッパー
- config
- local
- src
- log → アクセスログ他各種ログ格納
- pear → PEARディレクトリ
- smarty3.0b3
- cache → $Smarty->cache_dir(DO NOT make another.)
- configs → $Smarty->config_dir(DO NOT make another.)
- libs
- plugins
- templates
- templates_c → $Smarty->compile_dir(DO NOT make another.)
- svn
- repos → レポジトリ格納用
- www
- 69tracks → 69tracks [1]
- backyard → 管理用 [2]
- css
- images
- js
- lib
- monologue → monologue
- pear → PEAR GUI Interface
- test → 各種テスト用
- templates
- wiki → Pukiwiki
- php_info.php → PHP INFO
- blog
- mt4 → MovableType4
- freshreader → FreshReader
- lab
- diy → Do It Yourself Project
- tumblr → Tumblr Services
- nplll
- suidou → 水曜どうでしょうD陣日記アーカイブ
- archives
- lib
- templates
- switchover → SWITCH-OVER [3]
- tooearly → tooEarly [4]