8000 restore VScode on /t option · winpython/winpython@767728e · GitHub
[go: up one dir, main page]

Skip to content

Commit 767728e

Browse files
committed
restore VScode on /t option
1 parent 7ba768e commit 767728e

File tree

3 files changed

+45
-11
lines changed

3 files changed

+45
-11
lines changed

__init__.py

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# -*- coding: utf-8 -*-
2+
"""
3+
WinPython License Agreement (MIT License)
4+
-----------------------------------------
5+
6+
Copyright (c) 2012-2013 Pierre Raybaut
7+
Copyright (c) 2014-2023+ The Winpython development team https://github.com/winpython/
8+
9+
Permission is hereby granted, free of charge, to any person
10+
obtaining a copy of this software and associated documentation
11+
files (the "Software"), to deal in the Software without
12+
restriction, including without limitation the rights to use,
13+
copy, modify, merge, publish, distribute, sublicense, and/or sell
14+
copies of the Software, and to permit persons to whom the
15+
Software is furnished to do so, subject to the following
16+
conditions:
17+
18+
The above copyright notice and this permission notice shall be
19+
included in all copies or substantial portions of the Software.
20+
21+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
22+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
23+
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
24+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
25+
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
26+
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
27+
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
28+
OTHER DEALINGS IN THE SOFTWARE.
29+
"""
30+
31+
__version__ = '7.0.20230826'
32+
__license__ = __doc__
33+
__project_url__ = 'http://winpython.github.io/'

generate_a_winpython_distro.bat

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ echo ------------------
4646
echo 0.0 Initialize variables
4747
echo ------------------
4848

49-
if "%my_release_level%"=="" set my_release_level=b4
49+
if "%my_release_level%"=="" set my_release_level=b5
5050

5151
set my_basedir=%my_root_dir_for_builds%\bd%my_python_target%
5252

@@ -58,10 +58,6 @@ rem 2021-04-22 : path PyPy3 (as we don't try to copy PyPy3.exe to Python.exe)
5858
if "%target_python_exe%"=="" set target_python_exe=python.exe
5959

6060

61-
if %my_python_target%==37 (
62-
set my_python_target_release=3712
63-
set my_release=1
64-
)
6561
if %my_python_target%==38 (
6662
set my_python_target_release=3812
6763
set my_release=1
@@ -76,13 +72,11 @@ if %my_python_target%==310 (
7672
set my_release=2
7773
)
7874

79-
8075
if %my_python_target%==311 (
81-
set my_python_target_release=3114
82-
set my_release=1
76+
set my_python_target_release=3115
77+
set my_release=0
8378
)
8479

85-
8680
if %my_python_target%==312 (
8781
set my_python_target_release=3120
8882
set my_release=0

make.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,11 @@ def get_tool_path_dir(relpath):
8000
353353
if pandocexe is not None:
354354
pandocver = utils.get_pandoc_version(str(Path(pandocexe).parent))
355355
installed_tools += [("Pandoc", pandocver)]
356-
356+
vscodeexe = get_tool_path_file(r"\t\VSCode\Code.exe")
357+
if vscodeexe is not None:
358+
installed_tools += [
359+
("VSCode", utils.getFileProperties(vscodeexe)["FileVersion"])
360+
]
357361
tools = []
358362
for name, ver in installed_tools:
359363
metadata = wppm.get_package_metadata("tools.ini", name)
@@ -1831,11 +1835,14 @@ def _create_batch_scripts(self):
18311835
rem launcher for VScode
18321836
call "%~dp0env_for_icons.bat" %*
18331837
rem cd/D "%WINPYWORKDIR1%"
1838+
if exist "%WINPYDIR%\..\t\vscode\code.exe" (
1839+
"%WINPYDIR%\..\t\vscode\code.exe" %*
1840+
) else (
18341841
if exist "%LOCALAPPDATA%\Programs\Microsoft VS Code\code.exe" (
18351842
"%LOCALAPPDATA%\Programs\Microsoft VS Code\code.exe" %*
18361843
) else (
18371844
"code.exe" %*
1838-
)
1845+
))
18391846
18401847
""",
18411848
)

0 commit comments

Comments
 (0)
0