一个在windows下制作的文本格式文件在mac下打开发现中文乱码,如果需要正确显示,可用:
iconv -f GBK -t UTF-8 xxxxx.txt
一个在windows下制作的文本格式文件在mac下打开发现中文乱码,如果需要正确显示,可用:
iconv -f GBK -t UTF-8 xxxxx.txt
-- ~/.config/nvim/init.lua
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
print("Installing lazy.nvim... Please wait.")
vim.fn.system({
"git",
"clone",
"--filter=blob:none",
"https://github.com/folke/lazy.nvim.git",
"--branch=stable",
lazypath,
})
end
vim.opt.rtp:prepend(lazypath)
require("lazy").setup({
{
"nvim-treesitter/nvim-treesitter",
build = ":TSUpdate", -- ✅ 字符串形式,安全可靠
lazy = false,
init = function()
local ok, configs = pcall(require, "nvim-treesitter.configs")
if not ok then return end
configs.setup({
ensure_installed = { "lua", "python", "javascript", "typescript", "c", "cpp" },
highlight = { enable = true },
folding = { enable = true },
indent = { enable = true },
auto_install = true,
})
vim.opt.foldmethod = "expr"
vim.opt.foldexpr = "nvim_treesitter#foldexpr()"
vim.opt.foldlevel = 99
end,
},
})
在MacOS下,无法使用鼠标在Illustrator中选择正确的矢量目标。解决途径为:进入Illustrator的“首选项”——性能——取消勾选“GPU性能”,即可。
wordpress部署在阿里云,上传图片失败,提示限制图片像素尺寸在2560像素。
解决方法:进入阿里云的主机管理平台->高级环境设置->php.ini设置->php函数chmod设置->启动
import subprocess
p=subprocess.Popen(['sac'],stdin=subprocess.PIPE)
s=""
s+="echo on \n"
s+="r *.D.SAC\n"
s+="rmean\n"
s+="rtr\n"
s+="taper\n"
s+="bp co 0.5 12 n 4 p 2\n"
s+="decimate 4\n"
s+="w over\n"
s+="q\n"
p.communicate(s.encode())
先准备多段数据文件,用> Z作为数据头,后面跟随具体数值,如:
> -Z0.500000
如果使用GMT6.0绘图,代码可以写为:
gmt plot prov_poly.dat -Ccolor.cpt -G+z
上面一行是用来填写的,如果不带-G,则默认描边。
有网页中提出的codesign命令并没有解决这个问题
直接在终端下进入/Applications/MATLAB2023a/Contents/MacOS/
./MATLAB
一定要终端进入,鼠标点击不行。
主要是units出错,经查
macOS: ~/.ollama/models
Linux: /usr/share/ollama/.ollama/models
Windows: C:\Users\%username%\.ollama\models
FC = gfortran -ffixed-line-length-none