とつぜんPython(Anaconda)

sphinxドキュメンテーションしてみたくなって突然Python

 

参考

https://qiita.com/terahide/items/253eff6fba38c8f53746 

https://qiita.com/ozaki_physics/items/985188feb92570e5b82d

 

# 仮想環境一覧

conda info -e

 

# 仮想環境の削除

conda remove -n {環境名} --all

 

# 仮想環境作成

conda create -n document python=3.7.3 anaconda

 

# 仮想環境のactivate,deactivate

done
#
# To activate this environment, use
#
# $ conda activate document
#
# To deactivate an active environment, use
#
# $ conda deactivate

 

# パッケージ:Sphinxをインストール

conda install Sphinx

 

【TODO】あとで確認。とりあえず入れておく

conda install sphinx-autobuild

conda install sphinxcontrib-actdiag
conda install sphinxcontrib-blockdiag 
conda install sphinxcontrib-nwdiag
conda install sphinxcontrib-seqdiag

 

サクラエディタの最新版をインストール

シンタックスハイライトのテンプレートを適用

https://github.com/tohosaku/SakuraEditorTypeRest

 

 

 

これで準備ができた(はず)

チュートリアルを見ながら書いてみよう。

https://sphinx-users.jp/gettingstarted/make_project.html

 

【CodeIgniter×Nginx】設定などメモ

  • nginx.conf

#user nobody;
worker_processes 1;

#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;

#pid logs/nginx.pid;

events {
worker_connections 1024;
}

http {
include mime.types;
default_type application/octet-stream;

log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';

#access_log logs/access.log main;

sendfile on;
#tcp_nopush on;

#keepalive_timeout 0;
keepalive_timeout 65;

#gzip on;

server {
listen 80;
server_name localhost;
root C:/isa/isasrc;
index index.html index.php;

# set expiration of assets to MAX for caching
location ~* \.(ico|css|js|gif|jpe?g|png)(\?[0-9]+)?$ {
expires max;
log_not_found off;
}

location / {
try_files $uri $uri/ /index.php?/$uri;
}

#php-fpm
location ~* \.php$ {
fastcgi_pass 127.0.0.1:9000;
include fastcgi.conf;
}

}

}

 

$config['base_url'] = isset($_SERVER['HTTP_HOST']) ? 'http://' . $_SERVER['HTTP_HOST'] . '/' : '';

$config['index_page'] = '';