Skip to content

Conversation

@mjcheetham
Copy link
Member

Range-diff relative to main:

  1:  93deb77118 =   1:  3218429046 windows: ignore empty `PATH` elements
  2:  dcce099324 =   2:  0c7c5eb2cf is_Cygwin: avoid `exec`ing anything
  3:  43b9f3b889 =   3:  ac681d3437 Move is_<platform> functions to the beginning
  4:  7e19503b13 =   4:  832b054e69 Move the `_which` function (almost) to the top
  5:  262b7fccd7 =   5:  dafd42ebd9 Work around Tcl's default `PATH` lookup
  6:  9fec2c56cb =   6:  1a0b8d188c gitk(Windows): avoid inadvertently calling executables in the worktree
  7:  2c45054f59 =   7:  481fa54b95 t9350: point out that refs are not updated correctly
  8:  093da28aee =   8:  76ecf1303e transport-helper: add trailing --
  9:  b3f7ffb2f0 =   9:  0297838334 remote-helper: check helper status after import/export
 14:  62668ef774 =  10:  4227c4361d mingw: demonstrate a problem with certain absolute paths
 10:  29033a7783 =  11:  fd3f06f9d8 Always auto-gc after calling a fast-import transport
 17:  b4dabeec38 =  12:  b6569462c3 mingw: allow absolute paths without drive prefix
 11:  68bcbf9659 =  13:  8e56bf9008 mingw: include the Python parts in the build
 12:  4c1be4de47 =  14:  eaad65578f win32/pthread: avoid name clashes with winpthread
 13:  3ed5b49b03 =  15:  7eed53f94d git-compat-util: avoid redeclaring _DEFAULT_SOURCE
 16:  b527a1d0c8 =  16:  be79eca211 Import the source code of mimalloc v2.0.9
 15:  97db969ae7 =  17:  b868a1d216 clean: do not traverse mount points
 19:  3c9efc4a18 =  18:  e93a0a29cf mimalloc: adjust for building inside Git
 18:  a29dc8a689 =  19:  94ea2593b1 clean: remove mount points when possible
 20:  554b9ca0c4 =  20:  3d9c03225a mimalloc: offer a build-time option to enable it
 21:  13dd0f7d8a =  21:  6fad51a044 mimalloc: use "weak" random seed when statically linked
 29:  2b7a221f35 =  22:  13cc6f78d0 mingw: demonstrate a `git add` issue with NTFS junctions
 22:  7b9d3c09f4 =  23:  8303ce8e67 mingw: use mimalloc
 23:  bf20e9d5c7 =  24:  cf04b0ce44 Config option to disable side-band-64k for transport
 24:  7691240c8d =  25:  8aeb44e078 mingw: make sure `errno` is set correctly when socket operations fail
 25:  4a4bda0d4f =  26:  0479e9acc1 mingw: do resolve symlinks in `getcwd()`
 26:  d9ee6f1a84 =  27:  b0979620bb mingw: fix fatal error working on mapped network drives on Windows
 27:  bea455fd28 =  28:  d6c0b75379 clink.pl: fix MSVC compile script to handle libcurl-d.lib
 30:  ba60bb7880 =  29:  6cb054d9d6 vcxproj: unclash project directories with build outputs
 28:  677729f237 =  30:  f335719364 mingw: ensure valid CTYPE
 33:  78af2336b8 =  31:  33cde5cf8d t5505/t5516: allow running without `.git/branches/` in the templates
 31:  f1d296b8cd =  32:  dfad8ef0da mingw: allow `git.exe` to be used instead of the "Git wrapper"
 32:  aa1a791cf1 =  33:  f52a9b6640 strbuf_realpath(): use platform-dependent API if available
 37:  56fb137bb5 =  34:  e6d4ea64de t5505/t5516: fix white-space around redirectors
 34:  324ab16282 =  35:  3b52ab5397 mingw: ignore HOMEDRIVE/HOMEPATH if it points to Windows' system directory
 35:  61341a6ebb =  36:  0d6d69d580 http: use new "best effort" strategy for Secure Channel revoke checking
 36:  5b3c9c9c07 =  37:  e7eb1903b0 mingw: implement a platform-specific `strbuf_realpath()`
 38:  a7702815a9 =  38:  b1cae9b5f7 t3701: verify that we can add *lots* of files interactively
 39:  e04240c281 =  39:  1e322a889a git add -i: handle CR/LF line endings in the interactive input
 40:  da8699a16d =  40:  6847061dd1 commit: accept "scissors" with CR/LF line endings
 41:  e8c90f6326 =  41:  d6aef2b0bd t0014: fix indentation
 42:  2c55853176 =  42:  e2a3930ad8 git-gui: accommodate for intent-to-add files
 43:  7d788896ac =  43:  5e37720e6b clink.pl: fix libexpatd.lib link error when using MSVC
 44:  c04089f253 =  44:  9c9bd31cd6 Makefile: clean up .ilk files when MSVC=1
 45:  3a9b8c169c =  45:  43b873e87e vcbuild: add support for compiling Windows resource files
 46:  59c45d1c29 =  46:  a0fb5e41d6 config.mak.uname: add git.rc to MSVC builds
 47:  fa3f0b2a48 =  47:  ba55fbbed6 clink.pl: ignore no-stack-protector arg on MSVC=1 builds
 48:  fbbab51a82 =  48:  3fde2de3bd clink.pl: move default linker options for MSVC=1 builds
 49:  c0cf9e8fc3 =  49:  cfaef3a87d buildsystems: remove duplicate clause
 50:  79af9e682d =  50:  a386226a64 vcxproj: handle resource files, too
 51:  23d18e4800 =  51:  01669b97bb vcxproj: ignore -fno-stack-protector and -fno-common
 55:  13f106ec65 =  52:  1153390b2d vcxproj: handle GUI programs, too
 57:  f411651d27 =  53:  2bbd07ea30 win32: add a helper to run `git.exe` without a foreground window
 52:  fdc27327e1 =  54:  ec49106a22 vcpkg_install: detect lack of Git
 53:  b61f285a66 =  55:  e1d4f3b30d vcpkg_install: add comment regarding slow network connections
 54:  372f6ad405 =  56:  bf545bf9b6 vcxproj: support building Windows/ARM64 binaries
 56:  73a4d2fbba =  57:  430bc2f3fe vcbuild: install ARM64 dependencies when building ARM64 binaries
 58:  c678c3c4f6 =  58:  d8ac1d45eb vcbuild: add an option to install individual 'features'
 60:  01704b5905 =  59:  622464fd46 cmake: allow building for Windows/ARM64
 59:  0ef4afdaa1 =  60:  64f69a8ae1 git maintenance: avoid console window in scheduled tasks on Windows
 62:  acb81dbb5b =  61:  b7d1efb6cd ci(vs-build) also build Windows/ARM64 artifacts
 61:  7a1b782f62 =  62:  360dae5f31 cmake: install headless-git.
 63:  4023ab1008 =  63:  ca84007779 Add schannel to curl installation
 64:  9555abec1c =  64:  3d45e35178 subtree: update `contrib/subtree` `test` target
 65:  4c0a4a9ab9 =  65:  d618230ee7 cmake(): allow setting HOST_CPU for cross-compilation
 66:  269f1a1f0e =  66:  5e88bd44bf ci(vs-build): download the vcpkg artifacts using a dedicated Action
 67:  0bbe6223c8 =  67:  8ec1bc2570 mingw: allow for longer paths in `parse_interpreter()`
 68:  d7b762a557 =  68:  8d3ac385a6 compat/vcbuild: document preferred way to build in Visual Studio
 69:  bccb9e70e7 =  69:  d6480d9877 http: optionally send SSL client certificate
 70:  46578acbc7 =  70:  11a4e6d20c ci: run `contrib/subtree` tests in CI builds
 72:  5115238cf8 =  71:  8fe74bb169 hash-object: demonstrate a >4GB/LLP64 problem
 74:  60c04afffa =  72:  7482bccc82 hash_object_file_literally(): use size_t
 71:  107e29a9e7 =  73:  5adb31cc46 CMake: default Visual Studio generator has changed
 76:  f31959d0c1 =  74:  68d558ea61 object-file.c: use size_t for header lengths
 73:  7d86aaf08a =  75:  68a129ced5 .gitignore: add Visual Studio CMakeSetting.json file
 80:  a87f83a901 =  76:  1043e03dfc hash algorithms: use size_t for section lengths
 75:  31b9681a6a =  77:  17dfba05a6 CMakeLists: add default "x64-windows" arch for Visual Studio
 81:  585bb5d73f =  78:  586c9ceeca hash-object --stdin: verify that it works with >4GB/LLP64
 77:  7ebf6f2b48 =  79:  cef4cd1926 CMake: show Win32 and Generator_platform build-option values
 78:  4cafe5b811 =  80:  e7911298b8 init: do parse _all_ core.* settings early
 79:  51ea61ef3b =  81:  d891c36bc7 Enable the built-in FSMonitor as an experimental feature
 82:  6344040da8 =  82:  1583c03336 hash-object: add another >4GB/LLP64 test case
 83:  8eb9bb2883 =  83:  6d0a4e95e1 setup: properly use "%(prefix)/" when in WSL
 84:  f2faaafddd =  84:  38c82cba8a Add config option `windows.appendAtomically`
 85:  2db4ab3dee =  85:  341290608d hash-object: add a >4GB/LLP64 test case using filtered input
 86:  a3dd0bcc9f =  86:  e66d4a0b5e compat/mingw.c: do not warn when failing to get owner
 87:  220e95f589 =  87:  10f4a27d8a mingw: $env:TERM="xterm-256color" for newer OSes
 88:  db272b6c27 =  88:  50997b67c9 winansi: check result and Buffer before using Name
 89:  874601760c =  89:  8fb2552345 mingw: change core.fsyncObjectFiles = 1 by default
 90:  91ff5692b3 =  90:  b97e43133c vcxproj: allow building with `NO_PERL` again
 91:  f51cd73920 =  91:  72c91bf99d vcxproj: require C11
 92:  23f5c84b53 =  92:  af0bb2a43f vcxproj: ignore the `-pedantic` option
 93:  170db65a58 =  93:  a34de7f83a vcxproj: include reftable when committing `.vcxproj` files
 94:  fdfc5aed93 =  94:  aef7c7e672 vcxproj: handle libreftable_test, too
 95:  02d2977d55 =  95:  34343003af vcxproj: avoid escaping double quotes in the defines
 96:  5c7aebf87c =  96:  8d24a7bc56 ci: adjust Azure Pipeline for `runs_on_pool`
 97:  ab6345cef2 =  97:  22bb090694 ci: stop linking the `prove` cache
 98:  92f8086ede =  98:  f35a879a96 ci: reinstate Azure Pipelines support
 99:  ed5deb166e =  99:  d0394d37ed azure-pipeline: drop the `GETTEXT_POISON` job
100:  bba23ce387 = 100:  a1e5b0a1dc azure-pipeline: stop hard-coding `apt-get` calls
101:  e00d24a795 = 101:  317707345d azure-pipeline: drop the code to write to/read from a file share
102:  c5202db628 = 102:  7b82b758bd azure-pipeline: use partial clone/parallel checkout to initialize minimal-sdk
104:  a4a3fb934a = 103:  6592777439 bswap.h: add support for built-in bswap functions
103:  2dd5fab2e0 = 104:  aa517c78e2 azure-pipeline: downcase the job name of the `Linux32` job
105:  3fcad41926 = 105:  4b035aac2c config.mak.uname: add support for clangarm64
106:  0b81fade6a = 106:  a72fc0ece1 MinGW: link as terminal server aware
107:  f41f3b2bf2 = 107:  d65a7232d6 azure-pipeline: run static-analysis on jammy
108:  08e9b072f1 = 108:  dcc374cc21 Fix Windows version resources
109:  7ec4f13f94 = 109:  66cb5e4507 ci: create clangarm64-build.yml
110:  dd2ea10cea = 110:  06c51980ce status: fix for old-style submodules with commondir
111:  c3ca238042 = 111:  c3a6e89dec windows: skip linking `git-<command>` for built-ins
112:  c389eb9bca = 112:  ed69bf50d0 http: optionally load libcurl lazily
113:  db2c476a5a = 113:  9e9b5b8a31 http: support lazy-loading libcurl also on Windows
114:  83acbebd80 = 114:  6033251ac8 http: when loading libcurl lazily, allow for multiple SSL backends
115:  e493c1acb4 = 115:  346ad83c06 windows: fix Repository>Explore Working Copy
116:  7400bc762b = 116:  13a5c5071f mingw: do load libcurl dynamically by default
117:  d6530a1026 = 117:  6abb067097 Win32: make FILETIME conversion functions public
118:  d2516e6c6f = 118:  33319f0b8d Win32: dirent.c: Move opendir down
119:  47599bc192 = 119:  5e72cadde8 mingw: make the dirent implementation pluggable
120:  363c7cb569 = 120:  e1735911f2 Win32: make the lstat implementation pluggable
121:  7077efd0b2 = 121:  4cfa9b8ee5 add infrastructure for read-only file system level caches
122:  046c50b0cb = 122:  ad89986eba mingw: add a cache below mingw's lstat and dirent implementations
123:  91e79a0119 = 123:  fb19c952bc fscache: load directories only once
124:  063de2693c = 124:  e01940c64d fscache: add key for GIT_TRACE_FSCACHE
125:  4f22e39d6b = 125:  c2ff35acb4 fscache: remember not-found directories
126:  4715d48e5b = 126:  9c516ac90b fscache: add a test for the dir-not-found optimization
127:  6372dc890a = 127:  540ff688db add: use preload-index and fscache for performance
128:  39b6ebac58 = 128:  ecd8e034d1 dir.c: make add_excludes aware of fscache during status
129:  c7c8fb2e13 = 129:  ef82e9c2ab fscache: make fscache_enabled() public
130:  94657c8e46 = 130:  e7fe305d34 dir.c: regression fix for add_excludes with fscache
131:  88f48a3e8b = 131:  58ceae9acc fetch-pack.c: enable fscache for stats under .git/objects
132:  d74314b99e = 132:  9742f2efe8 checkout.c: enable fscache for checkout again
133:  39c3752943 = 133:  a7b9bdf073 Enable the filesystem cache (fscache) in refresh_index().
134:  40675f9973 = 134:  4747fffda8 fscache: use FindFirstFileExW to avoid retrieving the short name
135:  039eab9a48 = 135:  2bc187c416 status: disable and free fscache at the end of the status command
136:  488adea819 = 136:  66130be6e6 fscache: add GIT_TEST_FSCACHE support
137:  37429dafda = 137:  921bf49b6c fscache: add fscache hit statistics
138:  0136273134 = 138:  bd86d90b37 mem_pool: add GIT_TRACE_MEMPOOL support
139:  a9fb2964b5 = 139:  2b642bcf36 fscache: fscache takes an initial size
140:  f9b5ea29f8 = 140:  f88a01727a fscache: update fscache to be thread specific instead of global
141:  a41b646f5c = 141:  a8f72e726a fscache: teach fscache to use mempool
142:  fa663c8256 = 142:  eb98af7087 fscache: make fscache_enable() thread safe
143:  49e7a2d273 = 143:  8acebd2786 fscache: teach fscache to use NtQueryDirectoryFile
144:  82e84467d8 = 144:  de7e613f04 unpack-trees: enable fscache for sparse-checkout
145:  0b3d932e34 = 145:  e08f73dd9d fscache: remember the reparse tag for each entry
146:  34ee57ce56 = 146:  2131601dc7 fscache: implement an FSCache-aware is_mount_point()
148:  c1378c83c9 = 147:  19ee912669 git-gui: provide question helper for retry fallback on Windows
149:  bb4e3f44e2 = 148:  610d32520b git gui: set GIT_ASKPASS=git-gui--askpass if not set yet
151:  f7fe718e8a = 149:  cdcfab4c04 git-gui--askyesno: fix funny text wrapping
153:  cd568e87f3 = 150:  97370c2ed1 git-gui--askyesno: allow overriding the window title
155:  c60a6f97d3 = 151:  8108a00de9 respect core.hooksPath, falling back to .git/hooks
156:  77e6495c85 = 152:  5da66062cf git-gui--askyesno (mingw): use Git for Windows' icon, if available
147:  9bb2d36199 = 153:  3a858c59ac clean: make use of FSCache
150:  122cb43573 = 154:  89ea963181 gitk: Unicode file name support
152:  3fc9a513d1 = 155:  90040dde2d gitk: Use an external icon file on Windows
154:  86f611c692 = 156:  2fa7b96875 gitk: fix arrow keys in input fields with Tcl/Tk >= 8.6
157:  7a355b6e4d = 157:  e949d2ca09 gitk: make the "list references" default window width wider
158:  b368524169 = 158:  bd1ba699e4 pack-objects (mingw): demonstrate a segmentation fault with large deltas
159:  e28db144e8 = 159:  bded55ffb3 mingw: support long paths
160:  23cd1adff5 = 160:  ec9841568f Win32: fix 'lstat("dir/")' with long paths
161:  f0a80463f1 = 161:  0cb907cf2a mingw: Support `git_terminal_prompt` with more terminals
164:  ebaa689733 = 162:  e6b3d61aea compat/fsmonitor/fsm-*-win32: support long paths
165:  3a9d1ba414 = 163:  832f6dfb95 clean: suggest using `core.longPaths` if paths are too long to remove
162:  eee72a716c = 164:  9e413fb8e4 compat/terminal.c: only use the Windows console if bash 'read -r' fails
163:  f28b98c9f1 = 165:  3c46c8b196 mingw (git_terminal_prompt): do fall back to CONIN$/CONOUT$ method
166:  1fc8dadc9b = 166:  d6af24c5bf Unbreak interactive GPG prompt upon signing
167:  bb13a5960e = 167:  f8a0dd488c strbuf_readlink: don't call readlink twice if hint is the exact link size
168:  1b8f49e448 = 168:  a0a8305190 strbuf_readlink: support link targets that exceed PATH_MAX
169:  46b0ded534 = 169:  bd6352a1d0 lockfile.c: use is_dir_sep() instead of hardcoded '/' checks
170:  37c2e28e17 = 170:  969e46bdbc Win32: don't call GetFileAttributes twice in mingw_lstat()
171:  1557155bd5 = 171:  b81be67c55 Win32: implement stat() with symlink support
172:  2ce2208a58 = 172:  e41e46abb0 Win32: remove separate do_lstat() function
173:  beebbdb157 = 173:  a29a3905e8 Win32: let mingw_lstat() error early upon problems with reparse points
174:  3931a56ded = 174:  5246160715 mingw: teach fscache and dirent about symlinks
175:  334d3e072d = 175:  5258a7bb07 Win32: lstat(): return adequate stat.st_size for symlinks
176:  c0b3608e33 = 176:  162158cd19 Win32: factor out retry logic
177:  a08cfe59d4 = 177:  2ec9c1b150 Win32: change default of 'core.symlinks' to false
178:  0e29aa7e66 = 178:  621f575314 Win32: add symlink-specific error codes
179:  2294f8e2c3 = 179:  aaa64cc1b3 Win32: mingw_unlink: support symlinks to directories
180:  a15cc3944d = 180:  3dfdb239a2 Win32: mingw_rename: support renaming symlinks
181:  5f105e5e50 = 181:  0b76ed8305 Win32: mingw_chdir: change to symlink-resolved directory
182:  8d3c55602d = 182:  692cffcdc7 Win32: implement readlink()
183:  d92a1f86e8 = 183:  f977470149 mingw: lstat: compute correct size for symlinks
184:  9714d3fb8d = 184:  054fd07e16 Win32: implement basic symlink() functionality (file symlinks only)
185:  ac543f4df7 = 185:  48c81fd432 Win32: symlink: add support for symlinks to directories
186:  d5eca7b3c4 = 186:  cb7acac1cd mingw: try to create symlinks without elevated permissions
187:  c3a8bfd8e2 = 187:  ecb5c6594c mingw: emulate stat() a little more faithfully
188:  e993ce4b62 = 188:  46e6fb93bf mingw: special-case index entries for symlinks with buggy size
189:  f86ebb1fa7 = 189:  b5e62b70af mingw: introduce code to detect whether we're inside a Windows container
190:  5875222af6 = 190:  144d3ff729 mingw: when running in a Windows container, try to rename() harder
191:  4eb6570fad = 191:  d2e1e58a3a mingw: move the file_attr_to_st_mode() function definition
192:  d2194662d6 = 192:  bb65c4d43d mingw: Windows Docker volumes are *not* symbolic links
193:  f183dd1625 = 193:  09eb3e4456 Win32: symlink: move phantom symlink creation to a separate function
194:  9543a033ec = 194:  a5102ee51c Introduce helper to create symlinks that knows about index_state
195:  2650b4be2e = 195:  cb86163125 mingw: allow to specify the symlink type in .gitattributes
196:  25e1dca0eb = 196:  3ebb19b211 Win32: symlink: add test for `symlink` attribute
197:  03b505c7c5 = 197:  4f8aef2711 mingw: explicitly specify with which cmd to prefix the cmdline
198:  addcf25123 = 198:  c34949e229 mingw: when path_lookup() failed, try BusyBox
199:  1f91a8ac64 = 199:  f03869e431 test-lib: avoid unnecessary Perl invocation
200:  f15fd08932 = 200:  41772f821e test-tool: learn to act as a drop-in replacement for `iconv`
201:  74901bc25f = 201:  ce1cc22986 tests(mingw): if `iconv` is unavailable, use `test-helper --iconv`
202:  0ab33c37cf = 202:  899e94a0f2 gitattributes: mark .png files as binary
203:  5689f7a9f2 = 203:  4da2f6ff9a tests: move test PNGs into t/lib-diff/
204:  1bcdcf3878 = 204:  931a85f4c5 tests: only override sort & find if there are usable ones in /usr/bin/
205:  fac7d72ece = 205:  9568100e44 tests: use the correct path separator with BusyBox
206:  d078d4246f = 206:  cd48f439a4 mingw: only use Bash-ism `builtin pwd -W` when available
207:  d477630335 = 207:  016cb81b21 tests (mingw): remove Bash-specific pwd option
208:  f5c02841eb = 208:  74a967bbfa test-lib: add BUSYBOX prerequisite
209:  c549b5a0c3 = 209:  8fd5fd1e05 t5003: use binary file from t/lib-diff/
210:  b1215e33ac = 210:  fbf6f7fef8 t5532: workaround for BusyBox on Windows
211:  3e934825a6 = 211:  2078b221c6 t5605: special-case hardlink test for BusyBox-w32
212:  249439c076 = 212:  cbbd08127d t5813: allow for $PWD to be a Windows path
213:  b3c6f244f7 = 213:  6ee054b32f t9200: skip tests when $PWD contains a colon
214:  859e1c1b1c = 214:  6f70a0cd0b mingw: kill child processes in a gentler way
216:  06718424f7 = 215:  caf7d5af4c mingw: do not call xutftowcs_path in mingw_mktemp
215:  cc746ec9ac = 216:  84bdaf4333 mingw: add a Makefile target to copy test artifacts
217:  642bc32529 = 217:  f1aa6eb6b4 mingw: really handle SIGINT
218:  1b21cbee43 = 218:  874cf260bd Partially un-revert "editor: save and reset terminal after calling EDITOR"
222:  732da04fdc = 219:  24182c57a1 Describe Git for Windows' architecture [no ci]
223:  d146e95b4d = 220:  e8ddb6668c Modify the Code of Conduct for Git for Windows
224:  39b509aab1 = 221:  aceaa50f94 CONTRIBUTING.md: add guide for first-time contributors
219:  eb41e9c4c5 = 222:  9abd55a684 reset: reinstate support for the deprecated --stdin option
220:  ffd8e89445 = 223:  746ca76f76 fsmonitor: reintroduce core.useBuiltinFSMonitor
221:  a93cd55848 = 224:  f5ff040db2 Add a GitHub workflow to monitor component updates
225:  f4a6f7477a = 225:  902f9558b9 README.md: Add a Windows-specific preamble
226:  4f54c09caa = 226:  d74fda9374 Add an issue template
227:  de06de2623 = 227:  f8d56e230b Modify the GitHub Pull Request template (to reflect Git for Windows)
228:  024a796012 = 228:  06bae2d293 .github: Add configuration for the Sentiment Bot
229:  c878fc56ca = 229:  d605866ca9 Document how $HOME is set on Windows
230:  bd9880a68b = 230:  20a9e188cc SECURITY.md: document Git for Windows' policies

dennisameling and others added 30 commits June 1, 2023 10:14
Git's regular Makefile mentions that HOST_CPU should be defined when cross-compiling Git: https://github.com/git-for-windows/git/blob/37796bca76ef4180c39ee508ca3e42c0777ba444/Makefile#L438-L439

This is then used to set the GIT_HOST_CPU variable when compiling Git: https://github.com/git-for-windows/git/blob/37796bca76ef4180c39ee508ca3e42c0777ba444/Makefile#L1337-L1341

Then, when the user runs `git version --build-options`, it returns that value: https://github.com/git-for-windows/git/blob/37796bca76ef4180c39ee508ca3e42c0777ba444/help.c#L658

This commit adds the same functionality to the CMake configuration. Users can now set -DHOST_CPU= to set the target architecture.

Signed-off-by: Dennis Ameling <[email protected]>
We now have a GitHub Action to download and cache Azure Pipelines
artifacts (such as the `vcpkg` artifacts), hiding gnarly internals, and
also providing some robustness against network glitches. Let's use it.

Signed-off-by: Johannes Schindelin <[email protected]>
As reported in newren/git-filter-repo#225, it
looks like 99 bytes is not really sufficient to represent e.g. the full
path to Python when installed via Windows Store (and this path is used
in the hasb bang line when installing scripts via `pip`).

Let's increase it to what is probably the maximum sensible path size:
MAX_PATH. This makes `parse_interpreter()` in line with what
`lookup_prog()` handles.

Signed-off-by: Johannes Schindelin <[email protected]>
Signed-off-by: Vilius Šumskas <[email protected]>
We used to have that `make vcxproj` hack, but a hack it is. In the
meantime, we have a much cleaner solution: using CMake, either
explicitly, or even more conveniently via Visual Studio's built-in CMake
support (simply open Git's top-level directory via File>Open>Folder...).

Let's let the `README` reflect this.

Signed-off-by: Johannes Schindelin <[email protected]>
This adds support for a new http.sslAutoClientCert config value.

In cURL 7.77 or later the schannel backend does not automatically send
client certificates from the Windows Certificate Store anymore.

This config value is only used if http.sslBackend is set to "schannel",
and can be used to opt in to the old behavior and force cURL to send
client certificates.

This fixes git-for-windows#3292

Signed-off-by: Pascal Muller <[email protected]>
Because `git subtree` (unlike most other `contrib` modules) is included as
part of the standard release of Git for Windows, its stability should be
verified as consistently as it is for the rest of git. By including the
`git subtree` tests in the CI workflow, these tests are as much of a gate to
merging and indicator of stability as the standard test suite.

Signed-off-by: Victoria Dye <[email protected]>
On LLP64 systems, such as Windows, the size of `long`, `int`, etc. is
only 32 bits (for backward compatibility). Git's use of `unsigned long`
for file memory sizes in many places, rather than size_t, limits the
handling of large files on LLP64 systems (commonly given as `>4GB`).

Provide a minimum test for handling a >4GB file. The `hash-object`
command, with the  `--literally` and without `-w` option avoids
writing the object, either loose or packed. This avoids the code paths
hitting the `bigFileThreshold` config test code, the zlib code, and the
pack code.

Subsequent patches will walk the test's call chain, converting types to
`size_t` (which is larger in LLP64 data models) where appropriate.

Signed-off-by: Philip Oakley <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
The previous commit adds a test that demonstrates a problem in the
`hash-object --literally` command, manifesting in an unnecessary file
size limit on systems using the LLP64 data model (which includes
Windows).

Walking the affected code path is `cmd_hash_object()` >> `hash_fd()` >>
`hash_literally()` >> `hash_object_file_literally()`.

The function `hash_object_file_literally()` is the first with a file
length parameter (via a mem buffer). This commit changes the type of
that parameter to the LLP64 compatible `size_t` type.

There are no other uses of the function. The `strbuf` type is already
`size_t` compatible.

Note: The hash-object test does not yet pass. Subsequent commits will
continue to walk the call tree's lower level functions to identify
further fixes.

Signed-off-by: Philip Oakley <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
Correct some wording and inform users regarding the Visual Studio
changes (from V16.6) to the default generator.

Subsequent commits ensure that Git for Windows can be directly
opened in modern Visual Studio without needing special configuration
of the CMakeLists settings.

It appeares that internally Visual Studio creates it's own version of the
.sln file (etc.) for extension tools that expect them.

The large number of references below document the shifting of Visual Studio
default and CMake setting options.

refs: https://docs.microsoft.com/en-us/search/?scope=C%2B%2B&view=msvc-150&terms=Ninja

1. https://docs.microsoft.com/en-us/cpp/linux/cmake-linux-configure?view=msvc-160
(note the linux bit)
 "In Visual Studio 2019 version 16.6 or later ***, Ninja is the default
generator for configurations targeting a remote system or WSL. For more
information, see this post on the C++ Team Blog
[https://devblogs.microsoft.com/cppblog/linux-development-with-visual-studio-first-class-support-for-gdbserver-improved-build-times-with-ninja-and-updates-to-the-connection-manager/].

For more information about these settings, see CMakeSettings.json reference
[https://docs.microsoft.com/en-us/cpp/build/cmakesettings-reference?view=msvc-160]."

2. https://docs.microsoft.com/en-us/cpp/build/cmake-presets-vs?view=msvc-160
"CMake supports two files that allow users to specify common configure,
build, and test options and share them with others: CMakePresets.json
and CMakeUserPresets.json."

" Both files are supported in Visual Studio 2019 version 16.10 or later.
***"
3. https://devblogs.microsoft.com/cppblog/linux-development-with-visual-studio-first-class-support-for-gdbserver-improved-build-times-with-ninja-and-updates-to-the-connection-manager/
" Ninja has been the default generator (underlying build system) for
CMake configurations targeting Windows for some time***, but in Visual
Studio 2019 version 16.6 Preview 3*** we added support for Ninja on Linux."

4. https://docs.microsoft.com/en-us/cpp/build/cmakesettings-reference?view=msvc-160
" `generator`: specifies CMake generator to use for this configuration.
May be one of:

    Visual Studio 2019 only:
        Visual Studio 16 2019
        Visual Studio 16 2019 Win64
        Visual Studio 16 2019 ARM

    Visual Studio 2017 and later:
        Visual Studio 15 2017
        Visual Studio 15 2017 Win64
        Visual Studio 15 2017 ARM
        Visual Studio 14 2015
        Visual Studio 14 2015 Win64
        Visual Studio 14 2015 ARM
        Unix Makefiles
        Ninja

Because Ninja is designed for fast build speeds instead of flexibility
and function, it is set as the default. However, some CMake projects may
be unable to correctly build using Ninja. If this occurs, you can
instruct CMake to generate Visual Studio projects instead.

To specify a Visual Studio generator in Visual Studio 2017, open the
settings editor from the main menu by choosing CMake | Change CMake
Settings. Delete "Ninja" and type "V". This activates IntelliSense,
which enables you to choose the generator you want."

"To specify a Visual Studio generator in Visual Studio 2019, right-click
on the CMakeLists.txt file in Solution Explorer and choose CMake
Settings for project > Show Advanced Settings > CMake Generator.

When the active configuration specifies a Visual Studio generator, by
default MSBuild.exe is invoked with` -m -v:minimal` arguments."

5. https://docs.microsoft.com/en-us/cpp/build/cmake-presets-vs?view=msvc-160#enable-cmakepresetsjson-integration-in-visual-studio-2019
"Enable CMakePresets.json integration in Visual Studio 2019

CMakePresets.json integration isn't enabled by default in Visual Studio
2019. You can enable it for all CMake projects in Tools > Options >
CMake > General: (tick a box)" ... see more.

6. https://docs.microsoft.com/en-us/cpp/build/cmakesettings-reference?view=msvc-140
(whichever v140 is..)
"CMake projects are supported in Visual Studio 2017 and later."

7. https://docs.microsoft.com/en-us/cpp/overview/what-s-new-for-cpp-2017?view=msvc-150
"Support added for the CMake Ninja generator."

8. https://docs.microsoft.com/en-us/cpp/overview/what-s-new-for-cpp-2017?view=msvc-150#cmake-support-via-open-folder
"CMake support via Open Folder
Visual Studio 2017 introduces support for using CMake projects without
converting to MSBuild project files (.vcxproj). For more information,
see CMake projects in Visual
Studio[https://docs.microsoft.com/en-us/cpp/build/cmake-projects-in-visual-studio?view=msvc-150].
Opening CMake projects with Open Folder automatically configures the
environment for C++ editing, building, and debugging." ... +more!

9. https://docs.microsoft.com/en-us/cpp/build/cmake-presets-vs?view=msvc-160#supported-cmake-and-cmakepresetsjson-versions
"Visual Studio reads and evaluates CMakePresets.json and
CMakeUserPresets.json itself and doesn't invoke CMake directly with the
--preset option. So, CMake version 3.20 or later isn't strictly required
when you're building with CMakePresets.json inside Visual Studio. We
recommend using CMake version 3.14 or later."

10. https://docs.microsoft.com/en-us/cpp/build/cmake-presets-vs?view=msvc-160#enable-cmakepresetsjson-integration-in-visual-studio-2019
"If you don't want to enable CMakePresets.json integration for all CMake
projects, you can enable CMakePresets.json integration for a single
CMake project by adding a CMakePresets.json file to the root of the open
folder. You must close and reopen the folder in Visual Studio to
activate the integration.

11. https://docs.microsoft.com/en-us/cpp/build/cmake-presets-vs?view=msvc-160#default-configure-presets
***(doesn't actually say which version..)
"Default Configure Presets
If no CMakePresets.json or CMakeUserPresets.json file exists, or if
CMakePresets.json or CMakeUserPresets.json is invalid, Visual Studio
will fall back*** on the following default Configure Presets:

Windows example
JSON
{
  "name": "windows-default",
  "displayName": "Windows x64 Debug",
  "description": "Sets Ninja generator, compilers, x64 architecture,
build and install directory, debug build type",
  "generator": "Ninja",
  "binaryDir": "${sourceDir}/out/build/${presetName}",
  "architecture": {
    "value": "x64",
    "strategy": "external"
  },
  "cacheVariables": {
    "CMAKE_BUILD_TYPE": "Debug",
    "CMAKE_INSTALL_PREFIX": "${sourceDir}/out/install/${presetName}"
  },
  "vendor": {
    "microsoft.com/VisualStudioSettings/CMake/1.0": {
      "hostOS": [ "Windows" ]
    }
  }
},
"

Signed-off-by: Philip Oakley <[email protected]>
Continue walking the code path for the >4GB `hash-object --literally`
test. The `hash_object_file_literally()` function internally uses both
`hash_object_file()` and `write_object_file_prepare()`. Both function
signatures use `unsigned long` rather than `size_t` for the mem buffer
sizes. Use `size_t` instead, for LLP64 compatibility.

While at it, convert those function's object's header buffer length to
`size_t` for consistency. The value is already upcast to `uintmax_t` for
print format compatibility.

Note: The hash-object test still does not pass. A subsequent commit
continues to walk the call tree's lower level hash functions to identify
further fixes.

Signed-off-by: Philip Oakley <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
The CMakeSettings.json file is tool generated. Developers may track it
should they provide additional settings.

Signed-off-by: Philip Oakley <[email protected]>
Continue walking the code path for the >4GB `hash-object --literally`
test to the hash algorithm step for LLP64 systems.

This patch lets the SHA1DC code use `size_t`, making it compatible with
LLP64 data models (as used e.g. by Windows).

The interested reader of this patch will note that we adjust the
signature of the `git_SHA1DCUpdate()` function without updating _any_
call site. This certainly puzzled at least one reviewer already, so here
is an explanation:

This function is never called directly, but always via the macro
`platform_SHA1_Update`, which is usually called via the macro
`git_SHA1_Update`. However, we never call `git_SHA1_Update()` directly
in `struct git_hash_algo`. Instead, we call `git_hash_sha1_update()`,
which is defined thusly:

    static void git_hash_sha1_update(git_hash_ctx *ctx,
                                     const void *data, size_t len)
    {
        git_SHA1_Update(&ctx->sha1, data, len);
    }

i.e. it contains an implicit downcast from `size_t` to `unsigned long`
(before this here patch). With this patch, there is no downcast anymore.

With this patch, finally, the t1007-hash-object.sh "files over 4GB hash
literally" test case is fixed.

Signed-off-by: Philip Oakley <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
In Git-for-Windows, work on using ARM64 has progressed. The
commit 2d94b77 (cmake: allow building for Windows/ARM64, 2020-12-04)
failed to notice that /compat/vcbuild/vcpkg_install.bat will default to
using the "x64-windows" architecture for the vcpkg installation if not set,
but CMake is not told of this default. Commit 635b6d9 (vcbuild: install
ARM64 dependencies when building ARM64 binaries, 2020-01-31) later updated
vcpkg_install.bat to accept an arch (%1) parameter, but retained the default.

This default is neccessary for the use case where the project directory is
opened directly in Visual Studio, which will find and build a CMakeLists.txt
file without any parameters, thus expecting use of the default setting.

Also Visual studio will generate internal .sln solution and .vcxproj project
files needed for some extension tools. Inform users of the additional
.sln/.vcxproj generation.

** How to test:
 rm -rf '.vs' # remove old visual studio settings
 rm -rf 'compat/vcbuild/vcpkg' # remove any vcpkg downloads
 rm -rf 'contrib/buildsystems/out' # remove builds & CMake artifacts
 with a fresh Visual Studio Community Edition, File>>Open>>(git *folder*)
   to load the project (which will take some time!).
 check for successful compilation.
The implicit .sln (etc.) are in the hidden .vs directory created by
Visual Studio.

Signed-off-by: Philip Oakley <[email protected]>
Just like the `hash-object --literally` code path, the `--stdin` code
path also needs to use `size_t` instead of `unsigned long` to represent
memory sizes, otherwise it would cause problems on platforms using the
LLP64 data model (such as Windows).

To limit the scope of the test case, the object is explicitly not
written to the object store, nor are any filters applied.

The `big` file from the previous test case is reused to save setup time;
To avoid relying on that side effect, it is generated if it does not
exist (e.g. when running via `sh t1007-*.sh --long --run=1,41`).

Signed-off-by: Philip Oakley <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
Ensure key CMake option values are part of the CMake output to
facilitate user support when tool updates impact the wider CMake
actions, particularly ongoing 'improvements' in Visual Studio.

These CMake displays perform the same function as the build-options.txt
provided in the main Git for Windows. CMake is already chatty.
The setting of CMAKE_EXPORT_COMPILE_COMMANDS is also reported.

Include the environment's CMAKE_EXPORT_COMPILE_COMMANDS value which
may have been propogated to CMake's internal value.

Testing the CMAKE_EXPORT_COMPILE_COMMANDS processing can be difficult
in the Visual Studio environment, as it may be cached in many places.
The 'environment' may include the OS, the user shell, CMake's
own environment, along with the Visual Studio presets and caches.

See previous commit for arefacts that need removing for a clean test.

Signed-off-by: Philip Oakley <[email protected]>
In Git for Windows, `has_symlinks` is set to 0 by default. Therefore, we
need to parse the config setting `core.symlinks` to know if it has been
set to `true`. In `git init`, we must do that before copying the
templates because they might contain symbolic links.

Even if the support for symbolic links on Windows has not made it to
upstream Git yet, we really should make sure that all the `core.*`
settings are parsed before proceeding, as they might very well change
the behavior of `git init` in a way the user intended.

This fixes git-for-windows#3414

Signed-off-by: Johannes Schindelin <[email protected]>
If `feature.experimental` and `feature.manyFiles` are set and the user
has not explicitly turned off the builtin FSMonitor, we now start
the built-in FSMonitor by default.

Only forcing it when UNSET matches the behavior of UPDATE_DEFAULT_BOOL()
used for other repo settings.

Signed-off-by: Johannes Schindelin <[email protected]>
Signed-off-by: Jeff Hostetler <[email protected]>
To complement the `--stdin` and `--literally` test cases that verify
that we can hash files larger than 4GB on 64-bit platforms using the
LLP64 data model, here is a test case that exercises `hash-object`
_without_ any options.

Just as before, we use the `big` file from the previous test case if it
exists to save on setup time, otherwise generate it.

Signed-off-by: Philip Oakley <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
To verify that the `clean` side of the `clean`/`smudge` filter code is
correct with regards to LLP64 (read: to ensure that `size_t` is used
instead of `unsigned long`), here is a test case using a trivial filter,
specifically _not_ writing anything to the object store to limit the
scope of the test case.

As in previous commits, the `big` file from previous test cases is
reused if available, to save setup time, otherwise re-generated.

Signed-off-by: Philip Oakley <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
In the case of Git for Windows (say, in a Git Bash window) running in a
Windows Subsystem for Linux (WSL) directory, the GetNamedSecurityInfoW()
call in is_path_owned_By_current_side() returns an error code other than
ERROR_SUCCESS. This is consistent behavior across this boundary.

In these cases, the owner would always be different because the WSL
owner is a different entity than the Windows user.

The change here is to suppress the error message that looks like this:

  error: failed to get owner for '//wsl.localhost/...' (1)

Before this change, this warning happens for every Git command,
regardless of whether the directory is marked with safe.directory.

Signed-off-by: Derrick Stolee <[email protected]>
For Windows builds >= 15063 set $env:TERM to "xterm-256color" instead of
"cygwin" because they have a more capable console system that supports
this. Also set $env:COLORTERM="truecolor" if unset.

$env:TERM is initialized so that ANSI colors in color.c work, see
29a3963 (Win32: patch Windows environment on startup, 2012-01-15).

See git-for-windows#3629 regarding problems caused by always setting
$env:TERM="cygwin".

This is the same heuristic used by the Cygwin runtime.

Signed-off-by: Rafael Kitover <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
NtQueryObject under Wine can return a success but fill out no name.
In those situations, Wine will set Buffer to NULL, and set result to
the sizeof(OBJECT_NAME_INFORMATION).

Running a command such as

echo "$(git.exe --version 2>/dev/null)"

will crash due to a NULL pointer dereference when the code attempts to
null terminate the buffer, although, weirdly, removing the subshell or
redirecting stdout to a file will not trigger the crash.

Code has been added to also check Buffer and Length to ensure the check
is as robust as possible due to the current behavior being fragile at
best, and could potentially change in the future

This code is based on the behavior of NtQueryObject under wine and
reactos.

Signed-off-by: Christopher Degawa <[email protected]>
Atomic append on windows is only supported on local disk files, and it may
cause errors in other situations, e.g. network file system. If that is the
case, this config option should be used to turn atomic append off.

Co-Authored-By: Johannes Schindelin <[email protected]>
Signed-off-by: 孙卓识 <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
From the documentation of said setting:

	This boolean will enable fsync() when writing object files.

	This is a total waste of time and effort on a filesystem that
	orders data writes properly, but can be useful for filesystems
	that do not use journalling (traditional UNIX filesystems) or
	that only journal metadata and not file contents (OS X’s HFS+,
	or Linux ext3 with "data=writeback").

The most common file system on Windows (NTFS) does not guarantee that
order, therefore a sudden loss of power (or any other event causing an
unclean shutdown) would cause corrupt files (i.e. files filled with
NULs). Therefore we need to change the default.

Note that the documentation makes it sound as if this causes really bad
performance. In reality, writing loose objects is something that is done
only rarely, and only a handful of files at a time.

Signed-off-by: Johannes Schindelin <[email protected]>
This is another fall-out of the recent refactoring flurry.

Signed-off-by: Johannes Schindelin <[email protected]>
This fixes the build after 7bc341e (git-compat-util: add a test
balloon for C99 support, 2021-12-01).

Signed-off-by: Johannes Schindelin <[email protected]>
This is now passed by default, ever since 6a8cbc4 (developer: enable
pedantic by default, 2021-09-03).

Signed-off-by: Johannes Schindelin <[email protected]>
Since ef8a6c6 (reftable: utility functions, 2021-10-07) we not only
have a libreftable, but also a libreftable_test.

Signed-off-by: Johannes Schindelin <[email protected]>
Philip Oakley and others added 20 commits June 1, 2023 10:14
Git for Windows accepts pull requests; Core Git does not. Therefore we
need to adjust the template (because it only matches core Git's
project management style, not ours).

Also: direct Git for Windows enhancements to their contributions page,
space out the text for easy reading, and clarify that the mailing list
is plain text, not HTML.

Signed-off-by: Philip Oakley <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
The sentiment bot will help detect when things get too heated.
Hopefully.

Signed-off-by: Johannes Schindelin <[email protected]>
Git documentation refers to $HOME and $XDG_CONFIG_HOME often, but does not specify how or where these values come from on Windows where neither is set by default. The new documentation reflects the behavior of setup_windows_environment() in compat/mingw.c.

Signed-off-by: Alejandro Barreto <[email protected]>
These are Git for Windows' Git GUI and gitk patches. We will have to
decide at some point what to do about them, but that's a little lower
priority (as Git GUI seems to be unmaintained for the time being, and
the gitk maintainer keeps a very low profile on the Git mailing list,
too).

Signed-off-by: Johannes Schindelin <[email protected]>
This is the recommended way on GitHub to describe policies revolving around
security issues and about supported versions.

Signed-off-by: Johannes Schindelin <[email protected]>
…dvice

clean: suggest using `core.longPaths` if paths are too long to remove
This was pull request git-for-windows#1645 from ZCube/master

Support windows container.

Signed-off-by: Johannes Schindelin <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>
Handle Ctrl+C in Git Bash nicely

Signed-off-by: Johannes Schindelin <[email protected]>
A fix for calling `vim` in Windows Terminal caused a regression and was
reverted. We partially un-revert this, to get the fix again.

Signed-off-by: Johannes Schindelin <[email protected]>
This topic branch re-adds the deprecated --stdin/-z options to `git
reset`. Those patches were overridden by a different set of options in
the upstream Git project before we could propose `--stdin`.

We offered this in MinGit to applications that wanted a safer way to
pass lots of pathspecs to Git, and these applications will need to be
adjusted.

Instead of `--stdin`, `--pathspec-from-file=-` should be used, and
instead of `-z`, `--pathspec-file-nul`.

Signed-off-by: Johannes Schindelin <[email protected]>
Originally introduced as `core.useBuiltinFSMonitor` in Git for Windows
and developed, improved and stabilized there, the built-in FSMonitor
only made it into upstream Git (after unnecessarily long hemming and
hawing and throwing overly perfectionist style review sticks into the
spokes) as `core.fsmonitor = true`.

In Git for Windows, with this topic branch, we re-introduce the
now-obsolete config setting, with warnings suggesting to existing users
how to switch to the new config setting, with the intention to
ultimately drop the patch at some stage.

Signed-off-by: Johannes Schindelin <[email protected]>
…updates

Start monitoring updates of Git for Windows' component in the open
Add a README.md for GitHub goodness.

Signed-off-by: Johannes Schindelin <[email protected]>
@mjcheetham mjcheetham added this to the v2.41.0 milestone Jun 1, 2023
@mjcheetham mjcheetham requested review from dscho and vdye June 1, 2023 16:21
Copy link

@vdye vdye left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The range-diff and the actual diff both look good!

@mjcheetham
Copy link
Member Author

mjcheetham commented Jun 1, 2023

/git-artifacts

The tag-git workflow run was started

Copy link
Member

@dscho dscho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❤️

@mjcheetham
Copy link
Member Author

mjcheetham commented Jun 1, 2023

/release

The release-git workflow run was started

@rimrul rimrul linked an issue Jun 1, 2023 that may be closed by this pull request
@mjcheetham mjcheetham merged commit ff94e79 into git-for-windows:main Jun 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[New git version] v2.41.0