diff options
Diffstat (limited to 'misc')
-rw-r--r-- | misc/dist/html/fixed-size.html | 389 | ||||
-rw-r--r-- | misc/dist/html/full-size.html | 1 | ||||
-rw-r--r-- | misc/dist/html/offline-export.html | 42 | ||||
-rw-r--r-- | misc/dist/html/service-worker.js | 19 | ||||
-rw-r--r-- | misc/dist/ios_xcode/godot_ios.xcodeproj/project.pbxproj | 8 | ||||
-rw-r--r-- | misc/dist/ios_xcode/godot_ios.xcodeproj/xcshareddata/xcschemes/godot_ios.xcscheme | 10 | ||||
-rw-r--r-- | misc/dist/linux/godot.6 | 6 | ||||
-rw-r--r-- | misc/dist/linux/org.godotengine.Godot.xml | 6 | ||||
-rw-r--r-- | misc/dist/osx/editor.entitlements | 12 | ||||
-rw-r--r-- | misc/dist/osx/editor_mono.entitlements | 18 | ||||
-rw-r--r-- | misc/dist/osx_template.app/Contents/Info.plist | 2 | ||||
-rw-r--r-- | misc/dist/osx_tools.app/Contents/Info.plist | 2 | ||||
-rw-r--r-- | misc/dist/shell/_godot.zsh-completion | 2 | ||||
-rw-r--r-- | misc/dist/shell/godot.bash-completion | 2 | ||||
-rw-r--r-- | misc/dist/shell/godot.fish | 2 | ||||
-rwxr-xr-x | misc/hooks/canonicalize_filename.sh | 2 | ||||
-rwxr-xr-x | misc/hooks/pre-commit-clang-format | 15 | ||||
-rwxr-xr-x | misc/scripts/check_ci_log.py | 4 |
18 files changed, 108 insertions, 434 deletions
diff --git a/misc/dist/html/fixed-size.html b/misc/dist/html/fixed-size.html deleted file mode 100644 index 9d0a946497..0000000000 --- a/misc/dist/html/fixed-size.html +++ /dev/null @@ -1,389 +0,0 @@ -<!DOCTYPE html> -<html xmlns="http://www.w3.org/1999/xhtml" lang="" xml:lang=""> -<head> - <meta charset="utf-8" /> - <link id='-gd-engine-icon' rel='icon' type='image/png' href='favicon.png' /> - <title>$GODOT_PROJECT_NAME</title> - <style type="text/css"> - - body { - margin: 0; - border: 0 none; - padding: 0; - text-align: center; - background-color: #222226; - font-family: 'Noto Sans', Arial, sans-serif; - } - - - /* Godot Engine default theme style - * ================================ */ - - .godot { - color: #e0e0e0; - background-color: #3b3943; - background-image: linear-gradient(to bottom, #403e48, #35333c); - border: 1px solid #45434e; - box-shadow: 0 0 1px 1px #2f2d35; - } - - button.godot { - font-family: 'Droid Sans', Arial, sans-serif; /* override user agent style */ - padding: 1px 5px; - background-color: #37353f; - background-image: linear-gradient(to bottom, #413e49, #3a3842); - border: 1px solid #514f5d; - border-radius: 1px; - box-shadow: 0 0 1px 1px #2a2930; - } - - button.godot:hover { - color: #f0f0f0; - background-color: #44414e; - background-image: linear-gradient(to bottom, #494652, #423f4c); - border: 1px solid #5a5667; - box-shadow: 0 0 1px 1px #26252b; - } - - button.godot:active { - color: #fff; - background-color: #3e3b46; - background-image: linear-gradient(to bottom, #36343d, #413e49); - border: 1px solid #4f4c59; - box-shadow: 0 0 1px 1px #26252b; - } - - button.godot:disabled { - color: rgba(230, 230, 230, 0.2); - background-color: #3d3d3d; - background-image: linear-gradient(to bottom, #434343, #393939); - border: 1px solid #474747; - box-shadow: 0 0 1px 1px #2d2b33; - } - - - /* Canvas / wrapper - * ================ */ - - #container { - display: inline-block; /* scale with canvas */ - vertical-align: top; /* prevent extra height */ - position: relative; /* root for absolutely positioned overlay */ - margin: 0; - border: 0 none; - padding: 0; - background-color: #0c0c0c; - } - - #canvas { - display: block; - margin: 0 auto; - color: white; - } - - #canvas:focus { - outline: none; - } - - - /* Status display - * ============== */ - - #status { - position: absolute; - left: 0; - top: 0; - right: 0; - bottom: 0; - display: flex; - justify-content: center; - align-items: center; - /* don't consume click events - make children visible explicitly */ - visibility: hidden; - } - - #status-progress { - width: 244px; - height: 7px; - background-color: #38363A; - border: 1px solid #444246; - padding: 1px; - box-shadow: 0 0 2px 1px #1B1C22; - border-radius: 2px; - visibility: visible; - } - - #status-progress-inner { - height: 100%; - width: 0; - box-sizing: border-box; - transition: width 0.5s linear; - background-color: #202020; - border: 1px solid #222223; - box-shadow: 0 0 1px 1px #27282E; - border-radius: 3px; - } - - #status-indeterminate { - visibility: visible; - position: relative; - } - - #status-indeterminate > div { - width: 3px; - height: 0; - border-style: solid; - border-width: 6px 2px 0 2px; - border-color: #2b2b2b transparent transparent transparent; - transform-origin: center 14px; - position: absolute; - } - - #status-indeterminate > div:nth-child(1) { transform: rotate( 22.5deg); } - #status-indeterminate > div:nth-child(2) { transform: rotate( 67.5deg); } - #status-indeterminate > div:nth-child(3) { transform: rotate(112.5deg); } - #status-indeterminate > div:nth-child(4) { transform: rotate(157.5deg); } - #status-indeterminate > div:nth-child(5) { transform: rotate(202.5deg); } - #status-indeterminate > div:nth-child(6) { transform: rotate(247.5deg); } - #status-indeterminate > div:nth-child(7) { transform: rotate(292.5deg); } - #status-indeterminate > div:nth-child(8) { transform: rotate(337.5deg); } - - #status-notice { - margin: 0 100px; - line-height: 1.3; - visibility: visible; - padding: 4px 6px; - visibility: visible; - } - - - /* Debug output - * ============ */ - - #output-panel { - display: none; - max-width: 700px; - font-size: small; - margin: 6px auto 0; - padding: 0 4px 4px; - text-align: left; - line-height: 2.2; - } - - #output-header { - display: flex; - justify-content: space-between; - align-items: center; - } - - #output-container { - padding: 6px; - background-color: #2c2a32; - box-shadow: inset 0 0 1px 1px #232127; - color: #bbb; - } - - #output-scroll { - line-height: 1; - height: 12em; - overflow-y: scroll; - white-space: pre-wrap; - font-size: small; - font-family: "Lucida Console", Monaco, monospace; - } - </style> -$GODOT_HEAD_INCLUDE -</head> -<body> - <div id="container"> - <canvas id="canvas" width="640" height="480"> - HTML5 canvas appears to be unsupported in the current browser.<br /> - Please try updating or use a different browser. - </canvas> - <div id="status"> - <div id='status-progress' style='display: none;' oncontextmenu="event.preventDefault();"><div id ='status-progress-inner'></div></div> - <div id='status-indeterminate' style='display: none;' oncontextmenu="event.preventDefault();"> - <div></div> - <div></div> - <div></div> - <div></div> - <div></div> - <div></div> - <div></div> - <div></div> - </div> - <div id="status-notice" class="godot" style='display: none;'></div> - </div> - </div> - <div id="output-panel" class="godot"> - <div id="output-header"> - Output: - <button id='output-clear' class='godot' type='button' autocomplete='off'>Clear</button> - </div> - <div id="output-container"><div id="output-scroll"></div></div> - </div> - - <script type="text/javascript" src="$GODOT_BASENAME.js"></script> - <script type="text/javascript">//<![CDATA[ - - var engine = new Engine; - - (function() { - const EXECUTABLE_NAME = '$GODOT_BASENAME'; - const MAIN_PACK = '$GODOT_BASENAME.pck'; - const EXTRA_ARGS = JSON.parse('$GODOT_ARGS'); - const DEBUG_ENABLED = $GODOT_DEBUG_ENABLED; - const INDETERMINATE_STATUS_STEP_MS = 100; - - var canvas = document.getElementById('canvas'); - var statusProgress = document.getElementById('status-progress'); - var statusProgressInner = document.getElementById('status-progress-inner'); - var statusIndeterminate = document.getElementById('status-indeterminate'); - var statusNotice = document.getElementById('status-notice'); - - var initializing = true; - var statusMode = 'hidden'; - var indeterminiateStatusAnimationId = 0; - - function setStatusMode(mode) { - if (statusMode === mode || !initializing) - return; - [statusProgress, statusIndeterminate, statusNotice].forEach(elem => { - elem.style.display = 'none'; - }); - if (indeterminiateStatusAnimationId !== 0) { - cancelAnimationFrame(indeterminiateStatusAnimationId); - indeterminiateStatusAnimationId = 0; - } - switch (mode) { - case 'progress': - statusProgress.style.display = 'block'; - break; - case 'indeterminate': - statusIndeterminate.style.display = 'block'; - indeterminiateStatusAnimationId = requestAnimationFrame(animateStatusIndeterminate); - break; - case 'notice': - statusNotice.style.display = 'block'; - break; - case 'hidden': - break; - default: - throw new Error("Invalid status mode"); - } - statusMode = mode; - } - - function animateStatusIndeterminate(ms) { - var i = Math.floor(ms / INDETERMINATE_STATUS_STEP_MS % 8); - if (statusIndeterminate.children[i].style.borderTopColor == '') { - Array.prototype.slice.call(statusIndeterminate.children).forEach(child => { - child.style.borderTopColor = ''; - }); - statusIndeterminate.children[i].style.borderTopColor = '#dfdfdf'; - } - requestAnimationFrame(animateStatusIndeterminate); - } - - function setStatusNotice(text) { - while (statusNotice.lastChild) { - statusNotice.removeChild(statusNotice.lastChild); - } - var lines = text.split('\n'); - lines.forEach((line, index) => { - statusNotice.appendChild(document.createTextNode(line)); - statusNotice.appendChild(document.createElement('br')); - }); - }; - - engine.setProgressFunc((current, total) => { - if (total > 0) { - statusProgressInner.style.width = current/total * 100 + '%'; - setStatusMode('progress'); - if (current === total) { - // wait for progress bar animation - setTimeout(() => { - setStatusMode('indeterminate'); - }, 500); - } - } else { - setStatusMode('indeterminate'); - } - }); - - if (DEBUG_ENABLED) { - var outputRoot = document.getElementById("output-panel"); - var outputScroll = document.getElementById("output-scroll"); - var OUTPUT_MSG_COUNT_MAX = 400; - - document.getElementById('output-clear').addEventListener('click', () => { - while (outputScroll.firstChild) { - outputScroll.firstChild.remove(); - } - }); - - outputRoot.style.display = 'block'; - - function print(text) { - while (outputScroll.childElementCount >= OUTPUT_MSG_COUNT_MAX) { - outputScroll.firstChild.remove(); - } - var msg = document.createElement("div"); - if (String.prototype.trim.call(text).startsWith("**ERROR**")) { - msg.style.color = "#d44"; - } else if (String.prototype.trim.call(text).startsWith("**WARNING**")) { - msg.style.color = "#ccc000"; - } else if (String.prototype.trim.call(text).startsWith("**SCRIPT ERROR**")) { - msg.style.color = "#c6d"; - } - msg.textContent = text; - var scrollToBottom = outputScroll.scrollHeight - (outputScroll.clientHeight + outputScroll.scrollTop) < 10; - outputScroll.appendChild(msg); - if (scrollToBottom) { - outputScroll.scrollTop = outputScroll.scrollHeight; - } - }; - - function printError(text) { - if (!String.prototype.trim.call(text).startsWith('**ERROR**: ')) { - text = '**ERROR**: ' + text; - } - print(text); - } - - engine.setStdoutFunc(text => { - print(text); - console.log(text); - }); - - engine.setStderrFunc(text => { - printError(text); - console.warn(text); - }); - } - - function displayFailureNotice(err) { - var msg = err.message || err; - if (DEBUG_ENABLED) { - printError(msg); - } - console.error(msg); - setStatusNotice(msg); - setStatusMode('notice'); - initializing = false; - }; - - if (!Engine.isWebGLAvailable()) { - displayFailureNotice("WebGL not available"); - } else { - setStatusMode('indeterminate'); - engine.setCanvas(canvas); - engine.startGame(EXECUTABLE_NAME, MAIN_PACK, EXTRA_ARGS).then(() => { - setStatusMode('hidden'); - initializing = false; - }, displayFailureNotice); - } - })(); - //]]></script> -</body> -</html> diff --git a/misc/dist/html/full-size.html b/misc/dist/html/full-size.html index abc0479739..7afb6fdb6b 100644 --- a/misc/dist/html/full-size.html +++ b/misc/dist/html/full-size.html @@ -3,7 +3,6 @@ <head> <meta charset='utf-8' /> <meta name='viewport' content='width=device-width, user-scalable=no' /> - <link id='-gd-engine-icon' rel='icon' type='image/png' href='favicon.png' /> <title>$GODOT_PROJECT_NAME</title> <style type='text/css'> diff --git a/misc/dist/html/offline-export.html b/misc/dist/html/offline-export.html new file mode 100644 index 0000000000..41ab42b04b --- /dev/null +++ b/misc/dist/html/offline-export.html @@ -0,0 +1,42 @@ +<!DOCTYPE html> +<html lang="en"> +<head> + <meta charset="utf-8" /> + <meta http-equiv="X-UA-Compatible" content="IE=edge" /> + <meta name="viewport" content="width=device-width, initial-scale=1" /> + <title>You are offline</title> + <style> + html { + background-color: #000000; + color: #ffffff; + } + + body { + font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; + margin: 2rem; + } + + p { + margin-block: 1rem; + } + + button { + display: block; + padding: 1rem 2rem; + margin: 3rem auto 0; + } + </style> +</head> +<body> + <h1>You are offline</h1> + <p>This application requires an Internet connection to run for the first time.</p> + <p>Press the button below to try reloading:</p> + <button type="button">Reload</button> + + <script> + document.querySelector("button").addEventListener("click", () => { + window.location.reload(); + }); + </script> +</body> +</html> diff --git a/misc/dist/html/service-worker.js b/misc/dist/html/service-worker.js index d4eaed2b17..063e40a6cb 100644 --- a/misc/dist/html/service-worker.js +++ b/misc/dist/html/service-worker.js @@ -1,26 +1,15 @@ // This service worker is required to expose an exported Godot project as a // Progressive Web App. It provides an offline fallback page telling the user -// that they need an Internet conneciton to run the project if desired. +// that they need an Internet connection to run the project if desired. // Incrementing CACHE_VERSION will kick off the install event and force // previously cached resources to be updated from the network. const CACHE_VERSION = "@GODOT_VERSION@"; const CACHE_NAME = "@GODOT_NAME@-cache"; -const OFFLINE_URL = "offline.html"; +const OFFLINE_URL = "@GODOT_OFFLINE_PAGE@"; // Files that will be cached on load. -const CACHED_FILES = [ - "godot.tools.html", - "offline.html", - "godot.tools.js", - "godot.tools.worker.js", - "godot.tools.audio.worklet.js", - "logo.svg", - "favicon.png", -]; - +const CACHED_FILES = @GODOT_CACHE@; // Files that we might not want the user to preload, and will only be cached on first load. -const CACHABLE_FILES = [ - "godot.tools.wasm", -]; +const CACHABLE_FILES = @GODOT_OPT_CACHE@; const FULL_CACHE = CACHED_FILES.concat(CACHABLE_FILES); self.addEventListener("install", (event) => { diff --git a/misc/dist/ios_xcode/godot_ios.xcodeproj/project.pbxproj b/misc/dist/ios_xcode/godot_ios.xcodeproj/project.pbxproj index b9ad431e6e..fd69725a21 100644 --- a/misc/dist/ios_xcode/godot_ios.xcodeproj/project.pbxproj +++ b/misc/dist/ios_xcode/godot_ios.xcodeproj/project.pbxproj @@ -255,7 +255,7 @@ IPHONEOS_DEPLOYMENT_TARGET = 11.0; OTHER_LDFLAGS = "$linker_flags"; SDKROOT = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; + TARGETED_DEVICE_FAMILY = "$targeted_device_family"; }; name = Debug; }; @@ -294,7 +294,7 @@ IPHONEOS_DEPLOYMENT_TARGET = 11.0; OTHER_LDFLAGS = "$linker_flags"; SDKROOT = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; + TARGETED_DEVICE_FAMILY = "$targeted_device_family"; VALIDATE_PRODUCT = YES; }; name = Release; @@ -323,7 +323,7 @@ PRODUCT_BUNDLE_IDENTIFIER = $bundle_identifier; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = "$provisioning_profile_uuid_debug"; - TARGETED_DEVICE_FAMILY = "1,2"; + TARGETED_DEVICE_FAMILY = "$targeted_device_family"; VALID_ARCHS = "armv7 armv7s arm64 i386 x86_64"; WRAPPER_EXTENSION = app; }; @@ -353,7 +353,7 @@ PRODUCT_BUNDLE_IDENTIFIER = $bundle_identifier; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE = "$provisioning_profile_uuid_release"; - TARGETED_DEVICE_FAMILY = "1,2"; + TARGETED_DEVICE_FAMILY = "$targeted_device_family"; VALID_ARCHS = "armv7 armv7s arm64 i386 x86_64"; WRAPPER_EXTENSION = app; }; diff --git a/misc/dist/ios_xcode/godot_ios.xcodeproj/xcshareddata/xcschemes/godot_ios.xcscheme b/misc/dist/ios_xcode/godot_ios.xcodeproj/xcshareddata/xcschemes/godot_ios.xcscheme index b6beeb012f..d61a53d5c2 100644 --- a/misc/dist/ios_xcode/godot_ios.xcodeproj/xcshareddata/xcschemes/godot_ios.xcscheme +++ b/misc/dist/ios_xcode/godot_ios.xcodeproj/xcshareddata/xcschemes/godot_ios.xcscheme @@ -23,7 +23,7 @@ </BuildActionEntries> </BuildAction> <TestAction - buildConfiguration = "Debug" + buildConfiguration = "$default_build_config" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" shouldUseLaunchSchemeArgsEnv = "YES"> @@ -42,7 +42,7 @@ </AdditionalOptions> </TestAction> <LaunchAction - buildConfiguration = "Debug" + buildConfiguration = "$default_build_config" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" launchStyle = "0" @@ -67,7 +67,7 @@ </AdditionalOptions> </LaunchAction> <ProfileAction - buildConfiguration = "Debug" + buildConfiguration = "$default_build_config" shouldUseLaunchSchemeArgsEnv = "YES" savedToolIdentifier = "" useCustomWorkingDirectory = "NO" @@ -84,10 +84,10 @@ </BuildableProductRunnable> </ProfileAction> <AnalyzeAction - buildConfiguration = "Debug"> + buildConfiguration = "$default_build_config"> </AnalyzeAction> <ArchiveAction - buildConfiguration = "Debug" + buildConfiguration = "$default_build_config" revealArchiveInOrganizer = "YES"> </ArchiveAction> </Scheme> diff --git a/misc/dist/linux/godot.6 b/misc/dist/linux/godot.6 index 4140094813..3e5bdefdce 100644 --- a/misc/dist/linux/godot.6 +++ b/misc/dist/linux/godot.6 @@ -85,12 +85,6 @@ Force low\-DPI mode (macOS and Windows only). .TP \fB\-\-no\-window\fR Disable window creation (Windows only). Useful together with \fB\-\-script\fR. -.TP -\fB\-\-enable\-vsync\-via\-compositor\fR -When vsync is enabled, vsync via the OS' window compositor (Windows only). -.TP -\fB\-\-disable\-vsync\-via\-compositor\fR -Disable vsync via the OS' window compositor (Windows only). .SS "Debug options:" .TP \fB\-d\fR, \fB\-\-debug\fR diff --git a/misc/dist/linux/org.godotengine.Godot.xml b/misc/dist/linux/org.godotengine.Godot.xml index 2f647f71a6..e51179cd61 100644 --- a/misc/dist/linux/org.godotengine.Godot.xml +++ b/misc/dist/linux/org.godotengine.Godot.xml @@ -21,6 +21,12 @@ <glob pattern="*.escn"/> </mime-type> + <mime-type type="application/x-godot-shader"> + <comment>Godot Engine shader</comment> + <icon name="x-godot-shader" /> + <glob pattern="*.gdshader"/> + </mime-type> + <mime-type type="application/x-gdscript"> <comment>GDScript script</comment> <icon name="x-gdscript" /> diff --git a/misc/dist/osx/editor.entitlements b/misc/dist/osx/editor.entitlements new file mode 100644 index 0000000000..5496f65dcc --- /dev/null +++ b/misc/dist/osx/editor.entitlements @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> +<plist version="1.0"> +<dict> + <key>com.apple.security.device.audio-input</key> + <true/> + <key>com.apple.security.device.camera</key> + <true/> + <key>com.apple.security.cs.disable-library-validation</key> + <true/> +</dict> +</plist> diff --git a/misc/dist/osx/editor_mono.entitlements b/misc/dist/osx/editor_mono.entitlements new file mode 100644 index 0000000000..c61c287652 --- /dev/null +++ b/misc/dist/osx/editor_mono.entitlements @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> +<plist version="1.0"> +<dict> + <key>com.apple.security.cs.allow-dyld-environment-variables</key> + <true/> + <key>com.apple.security.cs.allow-jit</key> + <true/> + <key>com.apple.security.cs.allow-unsigned-executable-memory</key> + <true/> + <key>com.apple.security.cs.disable-library-validation</key> + <true/> + <key>com.apple.security.device.audio-input</key> + <true/> + <key>com.apple.security.device.camera</key> + <true/> +</dict> +</plist> diff --git a/misc/dist/osx_template.app/Contents/Info.plist b/misc/dist/osx_template.app/Contents/Info.plist index aad24935d0..8e221df946 100644 --- a/misc/dist/osx_template.app/Contents/Info.plist +++ b/misc/dist/osx_template.app/Contents/Info.plist @@ -36,6 +36,8 @@ </array> <key>NSPrincipalClass</key> <string>NSApplication</string> + <key>LSApplicationCategoryType</key> + <string>public.app-category.$app_category</string> <key>LSMinimumSystemVersion</key> <string>10.12</string> <key>LSMinimumSystemVersionByArchitecture</key> diff --git a/misc/dist/osx_tools.app/Contents/Info.plist b/misc/dist/osx_tools.app/Contents/Info.plist index 1c682f339f..8e70d4c203 100644 --- a/misc/dist/osx_tools.app/Contents/Info.plist +++ b/misc/dist/osx_tools.app/Contents/Info.plist @@ -38,6 +38,8 @@ </array> <key>NSPrincipalClass</key> <string>NSApplication</string> + <key>LSApplicationCategoryType</key> + <string>public.app-category.developer-tools</string> <key>LSMinimumSystemVersion</key> <string>10.12</string> <key>LSMinimumSystemVersionByArchitecture</key> diff --git a/misc/dist/shell/_godot.zsh-completion b/misc/dist/shell/_godot.zsh-completion index 8e14240b53..b29746bfc4 100644 --- a/misc/dist/shell/_godot.zsh-completion +++ b/misc/dist/shell/_godot.zsh-completion @@ -51,8 +51,6 @@ _arguments \ '--position[request window position]:position in X,Y format' \ '--low-dpi[force low-DPI mode (macOS and Windows only)]' \ '--no-window[disable window creation (Windows only), useful together with --script]' \ - "--enable-vsync-via-compositor[when Vsync is enabled, Vsync via the OS' window compositor (Windows only)]" \ - "--disable-vsync-via-compositor[disable Vsync via the OS' window compositor (Windows only)]" \ '(-d --debug)'{-d,--debug}'[debug (local stdout debugger)]' \ '(-b --breakpoints)'{-b,--breakpoints}'[specify the breakpoint list as source::line comma-separated pairs, no spaces (use %20 instead)]:breakpoint list' \ '--profiling[enable profiling in the script debugger]' \ diff --git a/misc/dist/shell/godot.bash-completion b/misc/dist/shell/godot.bash-completion index 14f2be37b1..03861e43f8 100644 --- a/misc/dist/shell/godot.bash-completion +++ b/misc/dist/shell/godot.bash-completion @@ -54,8 +54,6 @@ _complete_godot_options() { --position --low-dpi --no-window ---enable-vsync-via-compositor ---disable-vsync-via-compositor --debug --breakpoints --profiling diff --git a/misc/dist/shell/godot.fish b/misc/dist/shell/godot.fish index a485a1dcdb..1367665bbc 100644 --- a/misc/dist/shell/godot.fish +++ b/misc/dist/shell/godot.fish @@ -61,8 +61,6 @@ complete -c godot -l resolution -d "Request window resolution" -x complete -c godot -l position -d "Request window position" -x complete -c godot -l low-dpi -d "Force low-DPI mode (macOS and Windows only)" complete -c godot -l no-window -d "Disable window creation (Windows only), useful together with --script" -complete -c godot -l enable-vsync-via-compositor -d "When Vsync is enabled, Vsync via the OS' window compositor (Windows only)" -complete -c godot -l disable-vsync-via-compositor -d "Disable Vsync via the OS' window compositor (Windows only)" # Debug options: complete -c godot -s d -l debug -d "Debug (local stdout debugger)" diff --git a/misc/hooks/canonicalize_filename.sh b/misc/hooks/canonicalize_filename.sh index 5eecabf5bc..5fcae6ee70 100755 --- a/misc/hooks/canonicalize_filename.sh +++ b/misc/hooks/canonicalize_filename.sh @@ -13,7 +13,7 @@ # There should be no need to change anything below this line. # Canonicalize by recursively following every symlink in every component of the -# specified filename. This should reproduce the results of the GNU version of +# specified filename. This should reproduce the results of the GNU version of # readlink with the -f option. # # Reference: http://stackoverflow.com/questions/1055671/how-can-i-get-the-behavior-of-gnus-readlink-f-on-a-mac diff --git a/misc/hooks/pre-commit-clang-format b/misc/hooks/pre-commit-clang-format index 7c6e5fcb42..81bc412944 100755 --- a/misc/hooks/pre-commit-clang-format +++ b/misc/hooks/pre-commit-clang-format @@ -76,7 +76,8 @@ fi # To get consistent formatting, we recommend contributors to use the same # clang-format version as CI. -RECOMMENDED_CLANG_FORMAT_MAJOR="11" +RECOMMENDED_CLANG_FORMAT_MAJOR_MIN="11" +RECOMMENDED_CLANG_FORMAT_MAJOR_MAX="12" if [ ! -x "$CLANG_FORMAT" ] ; then message="Error: clang-format executable not found. Please install clang-format $RECOMMENDED_CLANG_FORMAT_MAJOR.x.x." @@ -99,11 +100,15 @@ if [ ! -x "$CLANG_FORMAT" ] ; then exit 1 fi -CLANG_FORMAT_VERSION="$(clang-format --version | cut -d' ' -f3)" -CLANG_FORMAT_MAJOR="$(echo "$CLANG_FORMAT_VERSION" | cut -d'.' -f1)" +# The returned string can be inconsistent depending on where clang-format comes from. +# Example output strings reported by `clang-format --version`: +# - Ubuntu: "Ubuntu clang-format version 11.0.0-2" +# - Fedora: "clang-format version 11.0.0 (Fedora 11.0.0-2.fc33)" +CLANG_FORMAT_VERSION="$(clang-format --version | sed "s/[^0-9\.]*\([0-9\.]*\).*/\1/")" +CLANG_FORMAT_MAJOR="$(echo "$CLANG_FORMAT_VERSION" | cut -d. -f1)" -if [ "$CLANG_FORMAT_MAJOR" != "$RECOMMENDED_CLANG_FORMAT_MAJOR" ]; then - echo "Warning: Your clang-format binary is the wrong version ($CLANG_FORMAT_VERSION, expected $RECOMMENDED_CLANG_FORMAT_MAJOR.x.x)." +if [[ "$CLANG_FORMAT_MAJOR" -lt "$RECOMMENDED_CLANG_FORMAT_MAJOR_MIN" || "$CLANG_FORMAT_MAJOR" -gt "$RECOMMENDED_CLANG_FORMAT_MAJOR_MAX" ]]; then + echo "Warning: Your clang-format binary is the wrong version ($CLANG_FORMAT_VERSION, expected between $RECOMMENDED_CLANG_FORMAT_MAJOR_MIN.x.x and $RECOMMENDED_CLANG_FORMAT_MAJOR_MAX.x.x)." echo " Consider upgrading or downgrading clang-format as formatting may not be applied correctly." fi diff --git a/misc/scripts/check_ci_log.py b/misc/scripts/check_ci_log.py index f2cdf95c7b..56c32b154c 100755 --- a/misc/scripts/check_ci_log.py +++ b/misc/scripts/check_ci_log.py @@ -53,11 +53,11 @@ if file_contents.find("ObjectDB instances leaked at exit") != -1: # execution of project if file_contents.find("Assertion failed") != -1: - print("ERROR: Assertion failed in project, check exectution log for more info") + print("ERROR: Assertion failed in project, check execution log for more info") sys.exit(1) # For now Godot leaks a lot of rendering stuff so for now we just show info -# about it and this needs to be reenabled after fixing this memory leaks. +# about it and this needs to be re-enabled after fixing this memory leaks. if file_contents.find("were leaked") != -1 or file_contents.find("were never freed") != -1: print("WARNING: Memory leak was found") |