Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-database
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
ygopro-database
Commits
fcea9aa7
Commit
fcea9aa7
authored
May 08, 2025
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add bat
parent
9cbc58ab
Pipeline
#36058
passed with stage
in 18 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
57 additions
and
0 deletions
+57
-0
setup.bat
setup.bat
+57
-0
No files found.
setup.bat
0 → 100644
View file @
fcea9aa7
@echo
off
setlocal
enabledelayedexpansion
echo
[
INFO
]
Checking
for
sqlite3
.exe
...
:: 1. Check environment or local path
where
sqlite3
.exe
>
nul
2
>
nul
if
%errorlevel%
==
0
(
set
"SQLITE3_BIN=sqlite3.exe"
echo
[
OK
]
Found
sqlite3
.exe
in
PATH
)
else
if
exist
".\bin\sqlite3.exe"
(
set
"SQLITE3_BIN=bin\sqlite3.exe"
echo
[
OK
]
Found
sqlite3
.exe
in
bin
\
)
else
(
echo
[
INFO
]
sqlite3
.exe
not
found
—
downloading
...
mkdir
bin
>
nul
2
>
nul
set
"SQLITE_URL=https://sqlite.org/2025/sqlite-tools-win-x64-3490200.zip"
set
"SQLITE_ZIP=bin\sqlite3.zip"
if
not
exist
"
%SQLITE_ZIP%
"
(
echo
[
DOWNLOAD
]
Downloading
SQLite
tools
...
powershell
-Command
"Invoke-WebRequest -Uri '
%SQLITE_URL%
' -OutFile '
%SQLITE_ZIP%
'"
||
goto
:fail
_download
)
echo
[
UNZIP
]
Extracting
...
powershell
-Command
"Expand-Archive -Path '
%SQLITE_ZIP%
' -DestinationPath 'bin' -Force"
||
goto
:fail
_unzip
if
not
exist
"bin\sqlite3.exe"
(
echo
[
ERROR
]
Failed
to
find
sqlite3
.exe
after
extraction
.
exit
/b
1
)
set
"SQLITE3_BIN=bin\sqlite3.exe"
echo
[
OK
]
sqlite3
installed
at
:
%SQLITE3
_BIN
%
)
:: 2. Git merge driver
echo
[
CONFIG
]
Setting
up
Git
merge
driver
...
git
config
merge
.sqlite
-merge
.name
"SQLite dump merge"
git
config
merge
.sqlite
-merge
.driver
"scripts/sqlite-merge.sh
%%O
%%A
%%B
%%L
%%P
"
:: 3. Git diff driver
echo
[
CONFIG
]
Setting
up
Git
diff
driver
...
git
config
diff
.sqlite
-diff
.textconv
"scripts/sqlite-diff.sh"
git
config
diff
.sqlite
-diff
.prompt
false
echo
[
DONE
]
Git
merge
&
diff
drivers
configured
successfully
.
exit
/b
0
:fail
_download
echo
[
ERROR
]
Failed
to
download
sqlite3
.
exit
/b
1
:fail
_unzip
echo
[
ERROR
]
Failed
to
extract
sqlite3
.zip.
exit
/b
1
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment