hexo

[!NOTE|label:references:]

prepare

[!NOTE|label:references:]

init

[!NOTE|label:references:]

install plugin

generate new pages

diable the default highlight settings

[!NOTE] default settings in _config.xml

$ sed '/highlight:/{n;s/^.$/\ \ enable: false/;n;s/^.$/\ \ line_number: false/;}' -i _config.xml

$ sed '/highlight:/{n;s/^.$/\ \ enable: false/}' -i _config.xml $ sed '/highlight:/{n;n;s/^.$/\ \ line_number: false/}' -i _config.xml

$ grep highlight: _config.yml -A 6 highlight: enable: false line_number: false auto_detect: false tab_replace: '' wrap: true hljs: false

theme

[!NOTE]

clone code

$ git submodule add https://github.com/imarslo/hexo-theme-snark.git themes/snark

$ git clone https://github.com/imarslo/hexo-theme-snark.git themes/snark $ sed '/highlight:/{n;s/^.$/\ \ enable: false/}' -i _config.xml $ sed '/highlight:/{n;n;s/^.$/\ \ line_number: false/}' -i _config.xml

$ git submodule sync --recursive $ git submodule update --init --recursive

use snark

  • _config.xml

[!NOTE|label:references:]

  • font-awesome.min.css

    [!TIP|label:references:]

    • deactive link:

      • https://cdn.bootcss.com/font-awesome/4.7.0/css/font-awesome.min.css

    • workable link:

      • 4.7.0:

        • https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css

        • https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css

        • https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css

      • 6.6.0

        • https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6.6.0/css/fontawesome.min.css

        • https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.6.0/css/fontawesome.min.css

  • jquery.min.js

    [!NOTE|label:references:]

    • activate link:

      • https://cdn.jsdelivr.net/npm/jquery@3.4.1/dist/jquery.min.js

      • https://code.jquery.com/jquery-4.0.0-beta.2.slim.min.js

      • https://cdnjs.cloudflare.com/ajax/libs/jquery/3.7.1/jquery.min.js

theme for code

[!TIP|label:references:]

commands

[!NOTE|label:references:]

  • options

    • --debug

    • --silent

    • --config customer.yml or --config custom.yml,custom2.json

    • --draft

new

[!NOTE|label:references:]

  • command format:

list

[!TIP|label:supported:]

  • hexo list page

  • hexo list post

  • hexo list tag

  • hexo list category

  • hexo list route

server

[!NOTE|label:references:]

  • Starts a local server. By default, this is at http://localhost:4000/

deploy

[!NOTE] deploy the website

deploy

[!NOTE|label:references:]

syntax highlighting

[!NOTE|label:references:]

  • code block

Last updated

Was this helpful?