I just bought a macbook pro to see how it is as a windows developer machine. I am using parallels desktop 9 for mac and it's really rocks. I want to use os x as much as poisable and only use windows for Visual Studio and windows only program, everything else I want to do in os x.
My main concern is git. I am sharing my projects folder with windows and my goal is to do all git related work from the mac bash terminal.
I am worried about line endings and special danish letters like ÅØÆ. Is it a bad idea to work in windows and commit in os x?
This is what I have found out so far:
- git config --global core.precomposeunicode true // so git can reconize øæå in filenames
- if it's a windows repository use core.autocrlf = true
- if it's on mac use core.autocrlf = input
So if I worked on a shared repository and everyone else is using windows with core.autocrlf = true what should I use when I commit from my mac, but do the coding in VS
I have no experience with Danish characters, but I work off windows through VMWare and I set the core.autocrif = true, since it will mess up my clickonce deployments otherwise.
That being said but I would match everyone else with core.autocrif = true, I have noticed things with line endings on the mac side if I'm editing db scripts but haven't ran into any issues with having this setting(mainly a web dev shop)
Related
How can I use unix commands in Gitkraken?
So I've recently picked up coding again, going back to the basics, and when I was learning previously I used windows and installed Git Bash which uses a Unix command-line environment if I'm not mistaken. The Odin Project (the website I am learning to code from) does not support Windows as an operating system when learning to code due to various reasons listed on their website. I believe that Windows is adequate and would like to continue using it instead of using VMware or VirtualBox to 'install' Linux. The only issue I'm having is executing commands using GitKraken. Some of the commands are different, so I was just wondering if there is a way to use Unix commands in GitKraken? At this point, I am just curious if it is possible. I can continue to use Git Bash, however, GitKraken displaying a visual map of my repos is very helpful.
Ex. How to open a file
$ open ./index.html - macOS
$ start index.html - Windows OS
Any help would be appreciated.
I'm using the Linux Subsystem for Windows (or whatever that new, fancy Ubuntu/Bash terminal is called in Windows 10). I'm using it in my Windows VM, which I am using to test an application developed and stored in Subversion.
I should point out that using the regular Windows command line, everything works perfectly with absolutely 0 issues. I just prefer Bash.
Anyway, svn is properly installed, and I can do commands like "svn status", "svn add", etc, in the Bash terminal no problem. However, if I try doing an "svn update" or "svn commit", that's when the problem happens.
I get the following error message:
myname#DESKTOP-VF4GBEA:~/Documents/Project$ svn update .
Updating '.':
svn: E000011: Unable to connect to a repository at URL 'https://some-url.com/trunk/Project'
svn: E000011: Error running context: Resource temporarily unavailable
I'm unsure why this is happening from the Bash terminal and not the Windows command line. I have Windows Defender disabled, no firewall there. I'm running Windows 10 Creators Edition (the latest version) in a virtual machine using VMWare Fusion on Mac OS Sierra. I do have Norton/Symantec protection running on the Mac, but it doesn't show anything having blocked a connection.
Regardless, doing these commands from the Windows command line, as I said, work perfectly fine.
Ok, I figured out the answer. The svn URL I was hitting was actually configured via my hosts file in the windows vm:
123.45.6.789 some-url.com
This was done in the windows file: C:\Windows\System32\drivers\etc\hosts. However, to get it to work in the Windows Bash Terminal, it needed to also be configured in /etc/hosts. That was the issue.
Ok, this is good to know. I guess the Bash/Windows thing uses all of its own configurations.
I'm developing on windows but have installed Bash for Windows (basically a Unix terminal for those who don't know about Windows 10 anniversary update). I installed git through this terminal (sudo apt-get install git) as opposed to downloading it as a Windows application from GitHub.
I'm now trying to integrate Git into Android Studio, and it's asking for a path to the Git executable. Because I didn't download it as a Windows application, there is no .exe, and instead I've tried to give the path C:\Users\Faizan\AppData\Local\lxss\rootfs\usr\bin\git which is where the terminal tells me where Git is when I type type git. I didn't really expect this to work because it's not an .exe but I'm stuck on ideas from here.
How can I make this work without having to download Git for Windows? How do people who develop on Unix systems deal with this path as they don't have an executable file either?
You still have to download Git For Windows.
Try the portable edition: PortableGit-2.10.0-64-bit.7z.exe
It comes with a bash, but even without opening a bash, you sttill have (in a regular Windows CMD session) 200+ Linux commands in <yourGit2.10>\usr\bin.
And of course, it has a git.exe, which is what your Android Studio needs.
I have Windows 8.1 on my laptop and I've installed Git. If I type git --version in Windows' command prompt, the result is git version 1.8.5.2.msysgit.0. I can commit and update all the stuff on the server, everything works fine.
At the same time, I'd like to have a GUI for that so I've installed GitHub for Windows. Unfortunately, it does not let me commit my changes as it report that there is an error as suggests opening a shell (also console-like, but looks different from usual Windows' cmd). If I type in that shell git --version I get git version 1.8.4.msysgit.0 so apparently the GUI app uses an older version of git than the one I need, although I have a needed version of Git installed on my computer.
I appreciate any hints on how to make the GUI app to use the new version of git. If any details are still needed, please tell me - I'll provide them asap. Thanks
You will find the git (embedded in G4W -- GitHub for Windows as SLaks mentions) in
%LOCALAPPDATA%\GitHub\Portable_Git_xxxxx\
(See "Can the credentials stored in Github for Windows be shared with the whole operating system?")
You can try and replace that folder by a portable Git, PortableGit-1.8.5.2-preview20131230.7z: once uncompressed, you can rename the folder with the same name 'Portable_Git_xxxxx' and see if that works.
Me and my friend set up Mercurial repository on Bitbucket for our project. He works on Windows while I use OSX. I installed Mercurial to OSX and cloned the repository only to find out that all scandinavian characters (äö) in files where interpreted wrongly. Also, folders which had those characters didn't get cloned properly.
Now, I suppose it has something to do with character encoding, which makes it somehow work on Windows, but not on OSX. I used Sourcetree as GUI for Mercurial and tried to find any character encoding settings with no results. What I should do to fix this problem? I have used GUI Mercurial on Windows before and never had problems like this.
You have usual "different encoding" problem.
OSX uses UTF8 (FIXME), Windows for Western-Europe 8bit chars (most probably) - ISO-8859-1
Before any CLI-operations in OSX you have to chcp to the same copepage, as it was on Win-side