gcclll / cheng92-comments

comments for https://www.cheng92.com
0 stars 0 forks source link

posts/let_s_talking_here #23

Open utterances-bot opened 2 years ago

utterances-bot commented 2 years ago

Let's talking here

https://blog.cheng92.com/posts/let_s_talking_here.html

gcclll commented 2 years ago

hello!!

gcclll commented 2 years ago
function syntaxHighlight(json) {
  if (typeof json != 'string') {
    json = JSON.stringify(json, undefined, 2)
  }
  json = json.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;')
  return json.replace(
    /("(\\u[a-zA-Z0-9]{4}|\\[^u]|[^\\"])*"(\s*:)?|\b(true|false|null)\b|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?)/g,
    function (match) {
      var cls = 'number'
      if (/^"/.test(match)) {
        if (/:$/.test(match)) {
          cls = 'key'
        } else {
          cls = 'string'
        }
      } else if (/true|false/.test(match)) {
        cls = 'boolean'
      } else if (/null/.test(match)) {
        cls = 'null'
      }
      return '<span class="' + cls + '">' + match + '</span>'
    }
  )
}
gcclll commented 2 years ago

macos + emacs

macOS 11, emacs+ brew 编译native-comp成功,但是编译eln不成功

App Launcher 的话可以用以下步骤:

把 eln-cache 文件删除 创建 early-init.el 并加入以下代码: (setenv "LIBRARY_PATH" "/usr/local/opt/gcc/lib/gcc/11:/usr/local/opt/gcc/lib/gcc/11/gcc/x86_64-apple-darwin21/11")