每日小结

Spring-doc OpenAPI 注解

@Operation @Response @Parameter

Ubuntu设置代理

启动clash for linux

  • 配置代理地址配置文件

  • 配置restAPI地址和访问密码

  • 将clash作为一个daemon进程:

    • 使用systemd:

      先创建配置文件/etc/systemd/system/clash.service

      1
      2
      3
      4
      5
      6
      7
      8
      [Unit]
      Description=Clash Daemon

      [Service]
      ExecStart=/usr/local/bin/clash -d /etc/clash/

      [Install]
      WantedBy=multi-user.target

      然后clash就成为了一个service, 可以通过systemctl命令启动, 通过journalctl命令查看日志等

    • 使用pm2: pm2 start clash

  • 在.bashrc或者.zshrc文件底部设置

1
2
3
4
5
export all_proxy='socks5://localhost:7891'
export http_proxy='http://localhost:7890'
export https_proxy='http://localhost:7890'
export ftp_proxy='http://localhost:7890'
export no_proxy='localhost,127.0.0.1'

Shell的类型

#shell的类型

常见的shell有sh, bash, zsh等,

查看当前使用的shell: echo $SHELL

查看系统中的所有shell: cat /etc/shells

#登录shell和非登录shell

#交互式shell和非交互式shell

#.profile 和 .xxshrc

  • /etc/profile 为系统的每个用户设置环境信息,当第一个用户登录时, 该文件被执行, 并从/etc/profile.d目录的配置文件中搜集shell的设置

  • /etc/xxshrc 为每一个运行xx shell的用户执行此文件. 当xx shell被打开时, 该文件被读取。有些linux版本中的/etc目录下已经没有了该文件。

  • ~/.profile 每个用户都可使用该文件输入专用于自己使用的shell信息, 当用户登录时,该文件仅仅执行一次 默认情况下,它设置一些环境变量,然后执行用户的.xxshrc文件.

  • ~/.xxshrc 该文件包含专用于某个用户的xx shell的配置, 当该用户登录时以及每次打开新的xx shell时,该文件被读取.

Hexo layout

hexo中每种不同的页面样式称为一个layout

根据md放置的位置不同, 使用的layout也不同