2018年12月
GitLab 实现仓库完全迁移,包括所有提交记录、分支、标签
具体命令如下:
cd <项目目录> git fetch --all git fetch --tags git remote set-url origin <项目的新仓库地址> git push origin --all git push --tags
参考文章:
https://developer.atlassian.com/blog/2016/01/totw-copying-a-full-git-repo/
新浪赴泰国曼谷和芭提雅团建
Mac OSX 目录操作遇到 Operation not permitted 问题
今天在安装 PHP 扩展的时候发现使用 sudo 还依然提示 "Operation not permitted"。
这是由于 10.13 版本加强了权限的限制,即 rootless 机制,可以进入恢复模式关闭 rootless 机制。
官方说明:https://developer.apple.com/videos/play/wwdc2015/706/
解决方案
重启 Mac,按 Command + R(Win 键盘:win + R)进入恢复模式
打开终端,输入命令:
csrutil disable
重启后让机器正常启动,可以在终端查看 rootless 状态:
csrutil status
显示
System Integrity Protection status: disabled.
正常情况下 rootless 已经关闭。
要想重新开启 rootless 机制,参考步骤 1,输入命令:
csrutil enable
使用 pdflatex 生成 Yii 2 中文权威指南 PDF
问题来源
https://github.com/yiisoft-contrib/yiiframework.com/issues/142 https://en.wikibooks.org/wiki/LaTeX/Internationalization#Chinese
解决方案
https://github.com/yiisoft-contrib/yiiframework.com/blob/master/commands/GuideController.php#L85
修改为:
// https://en.wikibooks.org/wiki/LaTeX/Internationalization#Chinese // TODO this does not work yet. See https://github.com/yiisoft-contrib/yiiframework.com/issues/142 file_put_contents("$pdfTarget/main.tex", str_replace(['\usepackage[british]{babel}', '\begin{document}', '\end{document}'], ['\usepackage{CJKutf8}', '\begin{document}' . PHP_EOL . '\begin{CJK}{UTF8}{gbsn}', '\end{CJK}' . PHP_EOL . '\end{document}'], file_get_contents("$pdfTarget/main.tex")));
{gbsn}
是“宋体”,所以前提是服务器已经安装中文的“宋体”字体。祝新浪二十周年生日快乐 - 大浪逐新,与时代同行
文章归档
文章日历
2018 年 12 月 | ||||||
---|---|---|---|---|---|---|
日 | 一 | 二 | 三 | 四 | 五 | 六 |
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 | 29 |
30 | 31 |
文章标签
- Linux
- Go
- Yii
- 新浪
- CentOS
- PHP
- Git
- WSL
- Composer
- Mac
- 入职
- Bootstrap
- pyenv
- UCenter
- 厦门
- 出差
- 长沙
- 湖南卫视
- 微博
- Tengine
- YUI
- 泰国
- pecl
- 优化
- GitLab
- 迁移
- rootless
- 年会
- 生日
- Tengin
- RedHat
- Sphinx
- cygwin
- Windows
- Tmux
- Zsh
- 升级
- MySQL
- sql_mode
- Shadowsockets
- 面向对象
- HTTP
- 状态码
- grep
- unoconv
- PPT
- Nginx
- htpasswd
- golang
最新评论
-
崔亮 于 19-05-23 评论了Tengine 2.2.2 配置 http2 协议出现的坑
-
王媛 于 19-01-31 评论了Yii China 是官方唯一认可的中文社区
-
三杯蛙 于 19-01-24 评论了Go 语言中 json 的操作以及常见问题
-
三杯蛙 于 19-01-24 评论了新浪赴泰国曼谷和芭提雅团建
-
巡洋舰 于 18-09-05 评论了CentOS 安装 PHP7
-
小不点 于 11-03-02 评论了WordPress 如何控制每页显示的条数
-
白领厕工 于 10-12-22 评论了关于 phpMyAdmin 免输入用户名和密码,直接进入管理界面
-
清晨的欣赏 于 10-08-04 评论了PHP 5.4 的新特性
-
易赛官网 于 10-07-27 评论了PHP 5.4 的新特性
-
文秘之家 于 10-07-17 评论了PHP 5.4 的新特性
常用工具
- 时间戳转换
- URL ENCODE/DECODE
- JSON
- 正则测试