Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
git-with-stata
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Rémi Le Gall
git-with-stata
Commits
f71bc436
Commit
f71bc436
authored
6 years ago
by
Maria Paula Caldas
Browse files
Options
Downloads
Patches
Plain Diff
Initial commit
parents
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.md
+36
-0
36 additions, 0 deletions
README.md
git-with-stata.stpr
+0
-0
0 additions, 0 deletions
git-with-stata.stpr
with
36 additions
and
0 deletions
README.md
0 → 100644
+
36
−
0
View file @
f71bc436
## Basic Stata and Git Workflow
You can call Git from the Stata command prompt via the
`shell`
function. For
more information on this command checkout the help documentation.
```
help shell
```
Basically, you can run any Git command from Stata by adding
`shell`
before it.
For example, to initialise a Git repository in the current working directory you
would have to run:
```
shell git init .
```
Which would return something like this:
```
#> Initialized empty Git repository in /path/to/your/repo
```
You can then go on to create a
`.gitignore`
, stage files and commit changes.
### What are the main advantages of this way of doing things?
-
You get to stay within Stata and don't have to switch back and forth between
Git bash and/or your favorite Git client.
### What are the main disadvantages?
-
No automatic text complition with the
`Tab`
key, as you would in Git bash.
-
No syntax highlighting.
-
You have to type an extra word (although granted, you could create a program).
This diff is collapsed.
Click to expand it.
git-with-stata.stpr
0 → 100644
+
0
−
0
View file @
f71bc436
File added
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment