Wilson Mar bio photo

Wilson Mar

Hello!

Calendar YouTube Github

LinkedIn

What are those files in repositories on GitHub

US (English)   Norsk (Norwegian)   Español (Spanish)   Français (French)   Deutsch (German)   Italiano   Português   Estonian   اَلْعَرَبِيَّةُ (Egypt Arabic)   Napali   中文 (简体) Chinese (Simplified)   日本語 Japanese   한국어 Korean

Overview

README.md

This specific name is detected by GitHub to display information about the project it is a part of.

.gitignore

Inside the .gitignore file at the root of a repo are folder and file names.

A file is .DS_Store which macOS generates for itself, and not useful by others.

.gitattributes

The .gitattribute file for a repo is within the .git/info folder.

The specifies how Git should diff (show changes between an index and a tree, changes between two trees, etc.) non-text files or having Git filter content before checking it into or out of Git.

These attributes tell Git to treat a specific file extension as binary data:

*.extension -crlf -diff
   *.extension binary

The attribute to auto-detect text files and perform LF normalization:

* text=auto
   *.md text
   *.csv text
   *.txt text
   *.js text
   *.php text
   *.png binary
   *.jpg binary
   

.gitattribes is used to help Git understand the file contents to better diff/render it. Used for merge resolution strategy (default, union etc.) as well.

Do not try and merge these files:

composer.lock -diff
yarn.lock -diff
public/build/js/*.js -diff
public/build/css/*.css -diff
*.map -diff
rev-manifest.json -diff

Attributes for Visual Studio select the merge resolution strategy (default, union, etc.):

*.cs diff=csharp
*.sln merge=union
*.csproj merge=union
*.vbproj merge=union
*.fsproj merge=union
*.dbproj merge=union

See https://git-scm.com/docs/gitattributes and https://medium.com/@pablorsk/be-a-git-ninja-the-gitattributes-file-e58c07c9e915

.editconfig

The contents of this file specifies the editing preferences used to create files in the project, such as the number of spaces for each indent. For example:

; This file is for unifying the coding style for different editors and IDEs.
; More information at http://EditorConfig.org
 
root = true
 
; Use 2 spaces for indentation in all Ruby files
 
[*.rb]
indent_style = space
indent_size = 2
 
[Rakefile]
indent_style = space
indent_size = 2
 
[Gemfile*]
indent_style = space
indent_size = 2
 
[config.ru]
indent_style = space
indent_size = 2
   

.iml

*.iml files are not really needed and can be gitignore’d.

*.iml files are created by IntelliJ IDEA based on the pom.xml file read by Maven to resolve dependencies of the project.

So .iml and pom.xml files contain duplicate information. When IntelliJ opens, it asks permission to auto import the pom.xml. IntelliJ doesn’t overwrite pom.xml with what is in .iml, so your pom.xml is the primary authority on settings.

The .iml file is needed by IntellJ to build/run/test/deploy/debug Maven projects in IDEA without using Maven. This enables experimentation with dependencies without changing the pom.xml. Note: that all the modifications you make will be reverted on next Maven import.

In other words, IDEA doesn’t understand Maven model directly, it converts it to its own project model used by all the subsystems, and the internal project information needs to be stored somewhere, hence the .iml files and .idea project directory. This way IDEA doesn’t need to analyze the pom file every time you open the project and resolve all the dependencies again, it’s done only when the pom.xml changes.

.travis.yml

This file specifies how the Travis.io web service builds the project.

language: ruby
rvm:
  - 2.0.0
  - 1.9.3
script: bundle exec rake install; bundle exec rake generate
   

A SVG image is added within the README.md text to flag whether Travis was successful at building.

CONTRIBUTING.md

This contains instructions for how others can contribute to the project.

Gemfile

This file is for Ruby-language projects to specify its dependencies, similar to what Maven does.x

Gemfile.lock

More

This is one of a series on Git and GitHub:

  1. Git and GitHub videos

  2. Why Git? (file-based backups vs Git clone)
  3. Git Markdown text

  4. Git basics (script)
  5. Git whoops (correct mistakes)
  6. Git messages (in commits)

  7. Git command shortcuts
  8. Git custom commands

  9. Git-client based workflows

  10. Git HEAD (Commitish references)

  11. Git interactive merge (imerge)
  12. Git patch
  13. Git rebase

  14. Git utilities
  15. Git-signing

  16. Git hooks
  17. GitHub data security
  18. TFS vs GitHub

  19. GitHub actions for automation JavaScript
  20. GitHub REST API
  21. GitHub GraphQL API
  22. GitHub PowerShell API Programming
  23. GitHub GraphQL PowerShell Module