zoukankan      html  css  js  c++  java
  • Typora结合Git打造完美的个人云笔记本

    Typera是一款非常好用的markdown编辑器,我之前一直用这个软件记录自己的学习笔记,但是由于一些原因,我仅仅只能将这些笔记存在本地,昨天突然突发奇想
    假如我将它和Git结合一下会不会就能打造自己的云笔记本了?上网搜索后,发现已经有人这样做了,我自己也实验了一下,确实很香。

    安装软件

    Typora
    
    https://www.typora.io/windows/typora-setup-x64.exe
    
    Git
    
    https://git-scm.com/download/win
    

    由于Git需要一些基本的配置,我已经配置好了,当初我是跟着廖雪峰老师的教程配置的:https://www.liaoxuefeng.com/wiki/1177760294764384

    配置远程仓库

    首先我们要注册一个github,然后开一个仓库作为自己的笔记仓库

    修改typera图片默认的位置

    文件->偏好设置->图像->输入相对路径,我这里输入的是./images,保持相对路径同步到github上才可以顺利的看到自己的图片

    修改主题

    文件->偏好设置->外观->从网站上下载一个主题压缩包->将解压后的文件夹中的所有文件粘贴到主题目录中

    主题目录位置在:

    文件->偏好设置->外观->打开主题文件夹

    进入自己的本地文件夹

    依次输入命令

    git init
    git add *
    git commit -m "first commit"
    git remote add origin https://gitee.com/xxxx/markdownFile.git
    git push -u origin master
    

    创建推送分支和拉取分支的脚本

    GitPull.bat

    echo "git pull orgin master...."
    
    git pull origin master
    

    GitPush.bat

    echo "Start submitting code to the local repository"
    echo "The current directory is:%cd%"
    git add *
    echo;
    
    
    
    echo "Commit the changes to the local repository"
    echo "please enter the commit info...."
    set /p message=
    set now=%date% %time%
    echo %now%
    git commit -m "%now% %message%"
    echo;
     
    echo "Commit the changes to the remote git server"
    git push
    echo;
     
    echo "Batch execution complete!"
    echo;
    

    之后当你写完推送上去点击推送脚本就可以了,获取最新笔记只需要点击拉取脚本就可以了,很方便

    参考:https://blog.csdn.net/oPengXiaoLiang/article/details/100678908

  • 相关阅读:
    arthas常用命令记录
    idea 的 http-client
    springboot 接口层参数校验 自定义参数校验
    Spring AOP 实现——使用annotation、pointcut、aspect
    Redis 热点名词
    SpringCloud注册发现配置
    【设计模式】-行为型-11-解释器模式
    【设计模式】-行为型-10-备忘录模式
    【设计模式】-创建型-9-访问者模式
    Kubernetes运行原理
  • 原文地址:https://www.cnblogs.com/mengxiaoleng/p/13890680.html
Copyright © 2011-2022 走看看