git

使用git拉取github上的项目

瘦欲@ 提交于 2021-02-18 03:15:34
一. 安装Git 去Git官网,下载安装包,一路点next,默认安装。 安装之后,在空白处右键,菜单显示有 Git GUI Here 和 Git Bash Here ,表示Git安装成功。 二. 配置Git 1.在任意地方,新建文件夹,为防止出错,最好保证该文件夹目录都是英文。 2.打开新建文件夹,空白处右键,菜单中选择 Git Bash here ,弹出命令行,输入命令 git init ,目录下会生成一个新的 .git 的文件夹,用于本地代码仓库。 3.配置本地仓库的账号和邮箱 $ git config -- global user.name "Your Name" $ git config -- global user.email "email@example.com" 4.为了避免每次远程访问需要输密码,将使用ssh登陆。ssh应该与本机信息绑定。查看自己电脑 C:\Users\Administrator 目录下是否有 .ssh 文件夹。如果没有就需要生成。 $ ssh-keygen -t rsa -C "youremail@example.com" 按 Enter 键一直到结束。 5.ssh只是本地详细,需要在Github中备份,才能被验证。打开自己的Github,在My Profile中,点击Add Public Key,title随意。 6.key中的内容在本机C盘中

IDEA中GitLab的使用

萝らか妹 提交于 2021-02-17 23:26:26
  首先安装git https://git-scm.com/downloads/ 下载对应的版本   下载好了,安装打开 Windows. 打开之后2步走, 与git连接 首先选择仓库,进行git init本地建立,然后配置你的名字与邮箱 git config --global user.name “用户名”,git config --global user.email “邮箱” 然后到当前目录生成公钥ssh-keygen -t rsa -C “你的邮箱” 建立之后去当前目录 寻找到钥匙,复制钥匙 然后去github上,点击自己头像,setting 选择SSH|key 标题随便起,key就是你刚刚在目录里的文件里复制的内容 然后add就行 之后就说明已经连接了,然后创建个Repository 打开git Bash 首先将你需要的上传的东西存放到你的指定仓库 然后add 文件名(带后缀的) git commit -m "版本说明" 之后就push 它 然后登录gitHub就会发现仓库里多了它,需要的话就pull拉它下来 现在进入正题 IDEA如何使用GitLab 1.打开IDEA,setting=>设置git路径 setting=>设置gitHub路径,都进行test. 2.打开你的项目 创建git 这里使用的是http 第一个是 gitLab里的项目url

Laravel系列之环境搭建 — VirtualBox+Vagrant+Homestead

怎甘沉沦 提交于 2021-02-17 22:56:40
一、为啥需要搭建环境   为了解决环境不统一问题,所以要搭建这么个玩意儿 二、步骤    Laravel对环境有所要求(不使用Homestead情况下),具体参考 官网    使用Homestead步骤   1. Homestead、VirtualBox、Vagrant     摘要:     Laravel 致力于让整个 PHP 开发体验变得愉快, 包括你的本地开发环境。 Vagrant 提供了一种简单,优雅的方式来管理和配置虚拟机。 Laravel Homestead 是一个官方预封装的 Vagrant box,它为你提供了一个完美的开发环境,而无需在本地机器安装 PHP 、Web 服务器和其他服务器软件。不用担心会搞乱你的操作系统!Vagrant boxes 是一次性的。如果出现问题,你可以在几分钟内销毁并创建 Box! Homestead 可以运行在任何 Windows,Mac,或 Linux 系统,它包括了 Nginx web 服务器, PHP 7.2,PHP 7.1,PHP 7.0,PHP 5.6, MySQL,PostgreSQL,Redis,Memcached, Node,以及开发 Laravel 应用程序所需要的东西。——摘自后盾人向军大叔(网站升级中,后期补链接)    1. 1 VirtualBox     VirtualBox 是 Oracle

Github: “This email will not be used for commit blame”

非 Y 不嫁゛ 提交于 2021-02-17 22:50:14
问题 How can I use a fake email address with Github? Following Github's since-changed instructions, I had a fake email like user@server.fake configured with git ( git config --global user.email "user@server.fake" ) and registered on my email settings page. It was linking my commits, but not since the past week or so, and it has a "(?)" tooltip saying: This email will not be used for commit blame My real email address is verified and blamable, but I want to keep it private. How can I use a fake one

常问的22道Java面试题,值得收藏【文末送书】

微笑、不失礼 提交于 2021-02-17 20:41:58
作者:爱茹一婉年 原文: https : //blog.csdn.net/qq_21924011/article/details/80399836 1)集合类:List和Set比较,各自的子类比较(ArrayList,Vector,LinkedList;HashSet,TreeSet) List:元素是有顺序的,元素可以重复因为每个元素有自己的角标(索引) |-- ArrayList:底层是数组结构,特点是:查询很快,增删稍微慢点,线程不同步:A线程将元素放在索引0位置,CPU调度线程A停止,B运行,也将元素放在索引0位置,当A和B同时运行的时候Size就编程了2. |-- LinkedList:底层使用的是链表数据结构,特点是:增删很快,查询慢。线程不安全,线程安全问题是由多个线程同时写或同时读写同一个资源造成的。 |--Vector:底层是数组数据结构,线程同步,Vector的方法前面加了synchronized关键字,被ArrayList代替了,现在用的只有他的枚举。 Set:元素是无序的,且不可以重复(存入和取出的顺序不一定一致),线程不同步。set底层是使用Map实现的,故可以通过ConcurrentHashMap的方式变通实现线程安全的Set。 |--HashSet:底层是哈希表数据结构。根据hashCode和equals方法来确定元素的唯一性。

Pushing all submodules recursively

…衆ロ難τιáo~ 提交于 2021-02-17 20:15:49
问题 I wrote the below script to push all the changes in the workspace, both in the submodules and the superproject. However, it sounds a little odd that, it is this complex to do what I want. Is there any better way, that I'm missing? #!/bin/bash if [ "$#" -ne 1 ]; then echo "Illegal number of parameters" exit fi SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" cd "${SCRIPT_DIR}/../submodule1" git status git add -A git commit -m "$1" git push origin master cd "${SCRIPT_DIR}/..

SDK Location not found

拈花ヽ惹草 提交于 2021-02-17 19:20:08
问题 I created recently a new local repo and pulled some code to it, from our remote repository. When i open the project, I receive a message in console: Gradle sync failed: SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable. Consult IDE log for more details I followed the instructions here to set the environment variable (Im in a Mac) and checked my local.properties: sdk.dir=/Users/admin/Library/Android/sdk So, both

How to enable git file tab completion with zsh compinit?

匆匆过客 提交于 2021-02-17 19:12:06
问题 I have a problem with the zsh tab completion: After running: autoload -U compinit compinit Git tab completion for files does not work any more. For example if I type git add my_f to complete my_file, nothing happens. The zsh git completion only seems to work for git branches and tags. Without the compinit stuff, git file completion works, but of course I'm missing out all the fancy branch completion stuff. So... Is there a way to make git file completion AND git branch completion possible at

How to enable git file tab completion with zsh compinit?

醉酒当歌 提交于 2021-02-17 19:12:05
问题 I have a problem with the zsh tab completion: After running: autoload -U compinit compinit Git tab completion for files does not work any more. For example if I type git add my_f to complete my_file, nothing happens. The zsh git completion only seems to work for git branches and tags. Without the compinit stuff, git file completion works, but of course I'm missing out all the fancy branch completion stuff. So... Is there a way to make git file completion AND git branch completion possible at