1. hello_wetty

    项目主页

    https://github.com/krishnasrinivas/wetty
    

    启动

    docker pull nathanleclaire/wetty
    docker run --name term -p 3000 -dt nathanleclaire/wetty
    

    查看端口

    CONTAINER ID    IMAGE          COMMAND       CREATED  STATUS    PORTS       NAMES
    7765a2c15edd  nathanleclaire/wetty  "node app.js -p 3000"  6 minutes ago   Up 6 minutes  0.0.0.0:32772->3000/tcp ...
  2. hello https

    letsencrypt

    https://letsencrypt.org/getting-started/

    certbot certonly --webroot -w /var/www/example -d example.com -d www.example.com -w /var/www/thing -d thing.is -d m.thing.is

    按照提示做就行

    help page

    https://github.com/certbot/certbot/issues/1736
    
    ./letsencrypt-auto certonly -a manual --rsa-key-size 4096 --email example@email.com ...
    Tagged as : op
  3. 安装pypy及其扩展

    pypy

    wget "https://bitbucket.org/pypy/pypy/downloads/pypy-2.6.0-linux64.tar.bz2"

    代理 #~/.pip/pip.conf [global] index-url = http://pypi.douban.com/simple

    numpy

    wget "http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-5.noarch.rpm" rpm -Uvh epel-release*rpm sudo yum install pypy pypy-devel pypy-libs

    sudo yum ...

    Tagged as : python
  4. elasticsearch做reindex

    • elasticsearch

    Switch doc_values=true to be the default for non-analyzed string fields · Issue #8312 · elastic/elasticsearch https://github.com/elastic/elasticsearch/issues/8312

    elastic/stream2es https://github.com/elastic/stream2es

    Heap: Sizing and Swapping https://www.elastic.co/guide/en/elasticsearch/guide/current/heap-sizing.html

    Changing Mapping with Zero Downtime ...

  5. php-each和foreach的区别

    • php

    通常情况下,我们使用foreach遍历数组,如下

        $arr = array(1, 2, 3, 4);
    
        foreach($arr as $k => $v){
            echo $v;
        }
        // output: 1234
    
        $arr = array(1, 2, 3, 4);
    
        while(list($k, $v) = each($arr)){
            echo $v;
        }
        // output: 1234
    

    当each出现在foreach后面的时候,就没了输出,因为foreach会把数组的迭代指针指到末尾

        $arr = array(1, 2, 3, 4);
    
        foreach($arr as $k => $v){
            echo ...
  6. 配置基于Vim的Python编程环境

    Wed 11 November 2015
    By Pezyn

    - vim

    指令

    ./configure --prefix=/usr --with-features=huge --enable-pythoninterp --with-python-config-dir=/usr/lib/python2.7/config
    

    参考

    • 配置基于Vim的Python编程环境 - Linux Wiki http://linux-wiki.cn/wiki/zh-hans/配置基于Vim的Python编程环境
    • debian 下编译安装同时支持 python2 和 python3 的 vim - Fermat618's Blog http://fermat618.is-programmer.com/posts/36038.html
  7. windows下的软件总结

    Wed 11 November 2015
    By Pezyn
    • windows

    杀毒软件

    首选MSE http://www.microsoft.com/zh-cn/security/pc-security/mse.aspx MSE装不了(没激活的系统可能装不了)的话,再试下 小红伞 http://rj.baidu.com/soft/detail/11761.html?ald

    输入法

    bing输入法

    压缩解压

    banndizip http://rj.baidu.com/soft/detail/23328.html?ald

    浏览器

    chrome http://rj.baidu.com/soft/detail/14744.html

    定时提醒你休息 ...

  8. mysql选出来的csv换行乱换怎么办

    1. sql中添加下面这句把换行符escape掉

        into outfile '/tmp/b.csv' fields terminated by ',' enclosed by '"' escaped by '\\' lines terminated by '\n'
    

    如下

        SELECT g.obj_id, g.obj_type, g.good_name, a.audio_author_name, a.audio_writer_name, a.audio_age_from, a.audio_age_to, a.editor_comment, a.audio_description into outfile '/tmp/b.csv' fields terminated by ',' enclosed by '"' escaped by ...
    Tagged as : daily

Pages

Categories

Tags

Page 1 / 2