Skip to content

Commit

Permalink
wip windows
Browse files Browse the repository at this point in the history
  • Loading branch information
vdelachaux committed Oct 25, 2023
1 parent 9906383 commit d26afd9
Show file tree
Hide file tree
Showing 13 changed files with 69 additions and 21 deletions.
Binary file modified Build/4DPop Git.4dbase.zip
Binary file not shown.
Binary file modified Build/Components/4DPop Git.4dbase/4DPop Git.4DZ
Binary file not shown.
4 changes: 2 additions & 2 deletions Build/Components/4DPop Git.4dbase/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
<key>CFBundleShortVersionString</key>
<string>20R4</string>
<key>CFBundleLongVersionString</key>
<string>20R4 (161)</string>
<string>20R4 (162)</string>
<key>CFBundleGetInfoString</key>
<string>20R4</string>
<key>CFBundleDisplayName</key>
<string>4DPop Git</string>
<key>CFBundleVersion</key>
<string>162</string>
<string>163</string>
<key>NSHumanReadableCopyright</key>
<string>©vdl 2020-2023</string>
</dict>
Expand Down
Binary file modified Build/Components/4DPop Git.4dbase/Libraries/lib4d-arm64.dylib
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Build/Components/4DPop Git.4dbase/Resources/InfoPlist.strings
Binary file not shown.
16 changes: 13 additions & 3 deletions Build/Components/4DPop Git.4dbase/Resources/en.lproj/gitlab.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,10 @@ Do you want to download the installer?</source>

Do you want to download the installer?</target>
</trans-unit>
<trans-unit id="JooE3WNXydNpOb1u6CueRw" resname="name(optional)">
<source>Name (optional)</source>
<target>Name (optional)</target>
</trans-unit>
</group>
<group resname="pattern">
<trans-unit id="RxY9OfmekBpp22bMfG8PUQ" resname="addPatternToGitignore">
Expand Down Expand Up @@ -254,9 +258,13 @@ with 4D "{version}"</target>
<source>Refresh</source>
<target>Refresh</target>
</trans-unit>
<trans-unit id="1RqbUAsfb2UASwgY39iNqw" resname="String 1">
<source/>
<target/>
<trans-unit id="1RqbUAsfb2UASwgY39iNqw" resname="saveSnapshot">
<source>Save Snapshot</source>
<target>Save Snapshot</target>
</trans-unit>
<trans-unit id="MRlvf5HFK2R9n75HQrSNug" resname="openWith">
<source>Open with {app}</source>
<target>Open with {app}</target>
</trans-unit>
</group>
<group resname="File">
Expand Down Expand Up @@ -294,4 +302,6 @@ with 4D "{version}"</target>





</xliff>
16 changes: 13 additions & 3 deletions Build/Components/4DPop Git.4dbase/Resources/fr.lproj/gitlab.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,10 @@ Do you want to download the installer?</source>

Voulez-vous télécharger l'installateur ?</target>
</trans-unit>
<trans-unit id="JooE3WNXydNpOb1u6CueRw" resname="name(optional)">
<source>Name (optional)</source>
<target>Nom (facultatif)</target>
</trans-unit>
</group>
<group resname="pattern">
<trans-unit id="RxY9OfmekBpp22bMfG8PUQ" resname="addPatternToGitignore">
Expand Down Expand Up @@ -254,9 +258,13 @@ avec 4D "{version}"</target>
<source>Refresh</source>
<target>Actualiser</target>
</trans-unit>
<trans-unit id="1RqbUAsfb2UASwgY39iNqw" resname="String 1">
<source/>
<target/>
<trans-unit id="1RqbUAsfb2UASwgY39iNqw" resname="saveSnapshot">
<source>Save Snapshot</source>
<target>Enregistrer l'instantané</target>
</trans-unit>
<trans-unit id="MRlvf5HFK2R9n75HQrSNug" resname="openWith">
<source>Open with {app}</source>
<target>Ouvrir avec {app}</target>
</trans-unit>
</group>
<group resname="File">
Expand Down Expand Up @@ -293,4 +301,6 @@ avec 4D "{version}"</target>





</xliff>
4 changes: 2 additions & 2 deletions Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
<key>CFBundleShortVersionString</key>
<string>20R4</string>
<key>CFBundleLongVersionString</key>
<string>20R4 (161)</string>
<string>20R4 (162)</string>
<key>CFBundleGetInfoString</key>
<string>20R4</string>
<key>CFBundleDisplayName</key>
<string>4DPop Git</string>
<key>CFBundleVersion</key>
<string>162</string>
<string>163</string>
<key>NSHumanReadableCopyright</key>
<string>©vdl 2020-2023</string>
</dict>
Expand Down
50 changes: 39 additions & 11 deletions Project/Sources/Classes/_GIT_Controller.4dm
Original file line number Diff line number Diff line change
Expand Up @@ -781,10 +781,10 @@ Function _openManager()
.line()\
.append(":xliff:viewOnGithub"; "github").icon("/RESOURCES/Images/Menus/gitHub.png").enable(This:C1470.Git.execute("config --get remote.origin.url"))

$menu.line()

If (Is macOS:C1572)

$menu.line()

If (File:C1566("/usr/local/bin/fork").exists)

$menu.append(Replace string:C233(Get localized string:C991("openWith"); "{app}"; "Fork"); "fork").icon("/RESOURCES/Images/Menus/fork.png")
Expand All @@ -799,8 +799,17 @@ Function _openManager()

Else

// TODO:On Windows
If (Folder:C1567(fk home folder:K87:24).file("AppData/Local/Fork/Fork.exe").exists)

$menu.append(Replace string:C233(Get localized string:C991("openWith"); "{app}"; "Fork"); "fork").icon("/RESOURCES/Images/Menus/fork.png")

End if

If (Folder:C1567(fk home folder:K87:24).file("AppData/Local/GitHubDesktop/GitHubDesktop.exe").exists)

$menu.append(Replace string:C233(Get localized string:C991("openWith"); "{app}"; "Github Desktop"); "githubDesktop").icon("/RESOURCES/Images/Menus/githubDesktop.png")

End if
End if

Case of
Expand Down Expand Up @@ -828,18 +837,36 @@ Function _openManager()
//———————————————————————————————————————
: ($menu.choice="fork")

SET ENVIRONMENT VARIABLE:C812("_4D_OPTION_CURRENT_DIRECTORY"; Folder:C1567(Folder:C1567(fk database folder:K87:14).platformPath; fk platform path:K87:2).platformPath)
LAUNCH EXTERNAL PROCESS:C811("/usr/local/bin/fork open")
SET ENVIRONMENT VARIABLE:C812("_4D_OPTION_CURRENT_DIRECTORY"; This:C1470.Git.cwd.platformPath)

If (Is macOS:C1572)

LAUNCH EXTERNAL PROCESS:C811("/usr/local/bin/fork open")

Else

LAUNCH EXTERNAL PROCESS:C811(Folder:C1567(fk home folder:K87:24).file("AppData/Local/Fork/Fork.exe").platformPath)

End if

//———————————————————————————————————————
: ($menu.choice="githubDesktop")

LAUNCH EXTERNAL PROCESS:C811("/usr/local/bin/github \""+Folder:C1567(Folder:C1567(fk database folder:K87:14).platformPath; fk platform path:K87:2).path+"\"")
SET ENVIRONMENT VARIABLE:C812("_4D_OPTION_CURRENT_DIRECTORY"; This:C1470.Git.cwd.platformPath)

If (Is macOS:C1572)

LAUNCH EXTERNAL PROCESS:C811("/usr/local/bin/github \""+This:C1470.Git.cwd.path+"\"")

Else

LAUNCH EXTERNAL PROCESS:C811(Folder:C1567(fk home folder:K87:24).file("AppData/Local/GitHubDesktop/GitHubDesktop.exe").platformPath+" "+This:C1470.Git.cwd.platformPath)

End if

//———————————————————————————————————————
End case


// === === === === === === === === === === === === === === === === === === === === === === === === === ===
Function _stageUnstageManager($e : cs:C1710.evt)

Expand Down Expand Up @@ -1521,10 +1548,11 @@ Function CreateGithubRepository($token : Text)
//// Try creating the repository
//$GithubAPI.method:="POST"
//$GithubAPI.body:={\
accept: "application/vnd.github+json"; \
name: $GithubAPI.CommpliantRepositoryName(Form.project); \
private: True\
}
accept: "application/vnd.github+json"; \
name: $GithubAPI.CommpliantRepositoryName(Form.project); \
private: True\
}

//$request:=4D.HTTPRequest.new($GithubAPI.URL+"/user/repos"; $GithubAPI)
//$request.wait()
//If ($request.response.status#201)
Expand Down
Binary file modified Resources/InfoPlist.strings
Binary file not shown.

0 comments on commit d26afd9

Please sign in to comment.