Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/workflows/build-portable.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@

name: Build Ditto Portable

on:
workflow_dispatch:

jobs:
build:
runs-on: windows-latest

steps:
- name: Checkout source
uses: actions/checkout@v4

- name: Add MSBuild to PATH
uses: microsoft/setup-msbuild@v2

- name: Restore NuGet packages
run: nuget restore CP_Main_10.sln

- name: Build Ditto x64
run: msbuild CP_Main_10.sln /p:Configuration=Release /p:Platform=x64

- name: Create portable ZIP
run: .\DittoSetup\BuildPortableZIP.bat "DittoPortable" bit64

- name: Upload portable build
uses: actions/upload-artifact@v4
with:
name: Ditto-Portable-x64
path: DittoSetup/output/DittoPortable*.zip
if-no-files-found: error
retention-days: 7
168 changes: 42 additions & 126 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,141 +15,57 @@ jobs:
runs-on: windows-latest

steps:
- uses: actions/checkout@v4

- name: Generate build number
id: buildnumber
uses: onyxmueller/build-tag-number@v1
with:
token: ${{secrets.GITHUB_TOKEN}}

- name: Set the value
run: |
echo "VERSION_FILENAME=3_25_${env:BUILD_NUMBER}_0" | Out-File -FilePath $env:GITHUB_ENV -Append
echo "VERSION_DOT_FILENAME=3.25.${env:BUILD_NUMBER}.0" | Out-File -FilePath $env:GITHUB_ENV -Append


- name: Checkout source
uses: actions/checkout@v4
with:
repository: hardcorehdc/Ditto
ref: master
clean: true
fetch-depth: 1

- name: Verify checkout
shell: pwsh
run: |
Write-Host "Workspace: $env:GITHUB_WORKSPACE"
Write-Host "GitHub repository: $env:GITHUB_REPOSITORY"
git status
Get-ChildItem -Force
if (!(Test-Path "CP_Main_10.sln")) {
throw "CP_Main_10.sln not found after checkout"
}

- name: Diagnose repository files
shell: pwsh
run: |
Write-Host "Workspace: $env:GITHUB_WORKSPACE"
Write-Host "Root files:"
Get-ChildItem $env:GITHUB_WORKSPACE -Force |
Format-Table Name, Mode
Write-Host "Solution files:"
Get-ChildItem $env:GITHUB_WORKSPACE -Filter "*.sln*" -Recurse |
Select-Object -ExpandProperty FullName

- name: Add MSBuild to PATH
uses: microsoft/setup-msbuild@v2

- name: Restore NuGet packages
working-directory: ${{env.GITHUB_WORKSPACE}}
run: nuget restore ${{env.SOLUTION_FILE_PATH}}

- name: Build
run: nuget restore CP_Main_10.sln

- name: Build Ditto x64
run: msbuild CP_Main_10.sln /p:Configuration=Release /p:Platform=x64

- name: Set Versions
run: |
DittoSetup\rcedit-x64 Release64\Ditto.exe --set-file-version ${{env.VERSION_DOT_FILENAME}} --set-product-version ${{env.VERSION_DOT_FILENAME}}

- name: upload-unsigned-exe
id: upload-unsigned-exe
uses: actions/upload-artifact@v4
with:
name: unsigned-exe
retention-days: 1
path: |
Release64\Ditto.exe
Release64\ICU_Loader.dll
Release64\Addins\DittoUtil.dll

- id: sign-exe
uses: signpath/github-action-submit-signing-request@v1.1
with:
api-token: '${{ secrets.SIGNPATH_API_TOKEN }}'
organization-id: 'fcf33ea4-4343-46b3-be50-f8fe64e1a900'
project-slug: 'Ditto'
artifact-configuration-slug: 'exe'
signing-policy-slug: 'release-signing'
github-artifact-id: '${{ steps.upload-unsigned-exe.outputs.artifact-id }}'
wait-for-completion: true
output-artifact-directory: '/Release64'

- name: Installer
uses: Minionguyjpro/Inno-Setup-Action@v1.2.7
with:
path: DittoSetup\DittoSetup_10.iss

- name: upload-unsigned-artifact
id: upload-unsigned-artifact
- name: Create portable ZIP
run: .\DittoSetup\BuildPortableZIP.bat "DittoPortable" bit64

- name: Upload portable build
uses: actions/upload-artifact@v4
with:
name: unsigned-intaller
retention-days: 1
path: DittoSetup\output\DittoSetup_${{env.VERSION_FILENAME}}.exe

- id: sing-installer
uses: signpath/github-action-submit-signing-request@v1.1
with:
api-token: '${{ secrets.SIGNPATH_API_TOKEN }}'
organization-id: 'fcf33ea4-4343-46b3-be50-f8fe64e1a900'
project-slug: 'Ditto'
artifact-configuration-slug: 'Installer'
signing-policy-slug: 'release-signing'
github-artifact-id: '${{ steps.upload-unsigned-artifact.outputs.artifact-id }}'
wait-for-completion: true
output-artifact-directory: '/DittoSetup/output'

- name: Build Portable
run: |
DittoSetup\BuildPortableZIP.bat "DittoPortable_${{env.VERSION_FILENAME}}" bit64

- name: Zip Debug Files
run: |
7z a DittoSetup\output\DittoDebug_${{env.VERSION_FILENAME}}.7z *.pdb -r
7z a DittoSetup\output\DittoDebug_${{env.VERSION_FILENAME}}.7z *.map -r

- name: Choco - Ditto
run: |
(Get-Content 'DittoSetup\Chocolatey\ditto.nuspec' -Raw).Replace("%version%", "${{env.VERSION_DOT_FILENAME}}") | Out-File 'DittoSetup\Chocolatey\ditto.nuspec'
copy DittoSetup\Output\DittoSetup_${{env.VERSION_FILENAME}}.exe DittoSetup\Chocolatey\tools\DittoSetup_${{env.VERSION_FILENAME}}.exe
cd DittoSetup\Chocolatey
choco pack
choco push --source https://push.chocolatey.org/ --key ${{ secrets.CHOCO_API_KEY}}
cd ..
cd ..

- name: Choco - Ditto.Install
run: |
(Get-Content 'DittoSetup\Chocolatey.install\ditto.nuspec' -Raw).Replace("%version%", "${{env.VERSION_DOT_FILENAME}}") | Out-File 'DittoSetup\Chocolatey.install\ditto.nuspec'
copy DittoSetup\output\DittoSetup_${{env.VERSION_FILENAME}}.exe DittoSetup\Chocolatey.install\tools\DittoSetup_${{env.VERSION_FILENAME}}.exe
cd DittoSetup\Chocolatey.install
choco pack
choco push --source https://push.chocolatey.org/ --key ${{ secrets.CHOCO_API_KEY}}
cd ..
cd ..

- name: Choco - Ditto.Portable
run: |
(Get-Content 'DittoSetup\Chocolatey.portable\ditto.nuspec' -Raw).Replace("%version%", "${{env.VERSION_DOT_FILENAME}}") | Out-File 'DittoSetup\Chocolatey.portable\ditto.nuspec'
copy DittoSetup\output\DittoPortable_${{env.VERSION_FILENAME}}.zip DittoSetup\Chocolatey.portable\tools\DittoPortable_${{env.VERSION_FILENAME}}.zip
cd DittoSetup\Chocolatey.portable
choco pack
choco push --source https://push.chocolatey.org/ --key ${{ secrets.CHOCO_API_KEY}}
cd ..
cd ..

- name: Build appx
run: |
7z x DittoSetup\output\DittoPortable_${{env.VERSION_FILENAME}}.zip -oDittoSetup\appx -r
(Get-Content 'DittoSetup\appx\appxmanifest.xml' -Raw).Replace("%version%", "${{env.VERSION_DOT_FILENAME}}") | Out-File 'DittoSetup\appx\appxmanifest.xml'
cd DittoSetup\appx

$env:Path += ";C:\Program Files (x86)\Windows Kits\10\bin\10.0.26100.0\x86"

makeappx.exe pack /f files.ini /p Ditto_${{env.VERSION_FILENAME}}.appx
signtool.exe sign -f my.pfx -fd SHA256 -v Ditto_${{env.VERSION_FILENAME}}.appx
cd ..
cd ..
copy DittoSetup\appx\Ditto_${{env.VERSION_FILENAME}}.appx DittoSetup\Output\Ditto_${{env.VERSION_FILENAME}}.appx

- name: Publish to GitHub
env:
token: ${{secrets.GITHUB_TOKEN}}
uploadPath: DittoSetup\output\
tag: ${{env.VERSION_FILENAME}}
previous_tag: 3.25.113.0
run: |
npm install ./DittoSetup/GitHubRelease
node ./DittoSetup/GitHubRelease/index.js

name: Ditto-Portable-x64
path: DittoSetup/output/DittoPortable*.zip
if-no-files-found: error
retention-days: 7
2 changes: 1 addition & 1 deletion CP_Main.rc
Original file line number Diff line number Diff line change
Expand Up @@ -904,7 +904,7 @@ BEGIN
PUSHBUTTON "About Language",IDC_BUTTON_ABOUT,207,60,106,14
EDITTEXT IDC_PATH,67,148,283,12,ES_AUTOHSCROLL
PUSHBUTTON "....",IDC_GET_PATH,354,148,14,12
LTEXT "Days",IDC_STATIC_DAYS,196,40,51,12,SS_CENTERIMAGE
LTEXT "Minutes",IDC_STATIC_DAYS,196,40,70,12,SS_CENTERIMAGE
LTEXT "Language",IDC_STATIC_LANGUAGE,9,60,36,12,SS_CENTERIMAGE
LTEXT "Include",IDC_STATIC_INCLUDE_APPS,14,191,36,13,SS_CENTERIMAGE
LTEXT "Exclude",IDC_STATIC_EXCLUDE_APPS,14,213,36,13,SS_CENTERIMAGE
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/Bulgarian.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "1" Author = "Стоян Димитров" Notes = "stoyanster от гмаил" LanguageCode = "bul">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">Групи</Item>
Expand Down Expand Up @@ -181,7 +181,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">Икона в системната лента</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">Максимален брой на пазените елементи</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">Елементите губят давност след</Item>
<Item English_Text = "Days" ID = "2043">дена</Item>
<Item English_Text = "Minutes" ID = "2043">минути</Item>
<Item English_Text = "Compact and Repair" ID = "1028"></Item>
<Item English_Text = "Check Now" ID = "1030">Проверяване</Item>
<Item English_Text = "Allow Duplicates" ID = "1037">Допускане на дублирани</Item>
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/Chinese Simplified.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "20260726" Author = "iYoung, wevsty, n78, xbeta, EX-XD" Notes = "" LanguageCode = "CHN">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">组</Item>
Expand Down Expand Up @@ -194,7 +194,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">在系统托盘显示图标</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">保存复制项目的最大数量</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">粘贴条目的过期日期</Item>
<Item English_Text = "Days" ID = "2043">天</Item>
<Item English_Text = "Minutes" ID = "2043">分钟</Item>
<Item English_Text = "Compact and Repair" ID = "1028">压缩和修复</Item>
<Item English_Text = "Check Now" ID = "1030">立即检查</Item>
<Item English_Text = "Allow Duplicates" ID = "1037">允许重复</Item>
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/Chinese Traditional.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "20250821" Author = "Minson,xbeta" Notes = "部分內容轉自簡體中文" LanguageCode = "chi">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">群組</Item>
Expand Down Expand Up @@ -182,7 +182,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">於系統列顯示圖示</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">儲存複製項的最大數量</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">貼上項目的保留期為</Item>
<Item English_Text = "Days" ID = "2043">天</Item>
<Item English_Text = "Minutes" ID = "2043">分鐘</Item>
<Item English_Text = "Compact and Repair" ID = "1028">壓縮及修復</Item>
<Item English_Text = "Check Now" ID = "1030">立刻檢查</Item>
<Item English_Text = "Allow Duplicates" ID = "1037">允許重複內容</Item>
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/Croatian.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "1" Author = "Robert Dragicevic" Notes = "robidragic@gmail.com" LanguageCode = "hrv">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">Skupina</Item>
Expand Down Expand Up @@ -147,7 +147,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">Prikaži ikonu u sistemskoj traci</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">Maksimalan broj spremljenih kopija</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">Zaljepljeni objekti se brišu nakon</Item>
<Item English_Text = "Days" ID = "2043">Dana</Item>
<Item English_Text = "Minutes" ID = "2043">minuta</Item>
<Item English_Text = "Compact and Repair" ID = "1028">Sažimaj i popravi</Item>
<Item English_Text = "Automatically check for updates online" ID = "1029">Automatski provjeri nove nadogradnje</Item>
<Item English_Text = "Check Now" ID = "1030">Provjeri sad</Item>
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/Czech.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "1" Author = "Yarca" Notes = "yarca@volny.cz" LanguageCode = "cze">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">Skupiny</Item>
Expand Down Expand Up @@ -150,7 +150,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">Zobrazit ikonu v systémové liště</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">Maximální počet uložených kopií</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">Vložené vstupy vyprší za</Item>
<Item English_Text = "Days" ID = "2043">dnů</Item>
<Item English_Text = "Minutes" ID = "2043">minut</Item>
<Item English_Text = "Compact and Repair" ID = "1028">Zkonsolidovat a opravit</Item>
<Item English_Text = "Check Now" ID = "1030">Ověřit nyní</Item>
<Item English_Text = "Allow Duplicates" ID = "1037">Povolit duplikáty</Item>
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/Danish.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "1" Author = "Carsten Bo Svitzer" Notes = "cbsvitzer@mail.dk" LanguageCode = "dan">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">Grupper</Item>
Expand Down Expand Up @@ -145,7 +145,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">Vis ikon på proceslinien</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">Maks antal gemte klip</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">Klip fjernes efter</Item>
<Item English_Text = "Days" ID = "2043">Dage</Item>
<Item English_Text = "Minutes" ID = "2043">Minutter</Item>
<Item English_Text = "Compact and Repair" ID = "1028">Komprimér och reparér</Item>
<Item English_Text = "Automatically check for updates online" ID = "1029">Søg automatisk efter opdateringer</Item>
<Item English_Text = "Check Now" ID = "1030">Søg nu</Item>
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/Deutsch.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "3.24" Author = "Dick Schiferli" Notes = "13.12.2023, based on 28.11.2019. Initially based on 'German.xml' by Guido Schroeder (11.01.2012) and Stephan Jaeger" LanguageCode="ger">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">Gruppen</Item>
Expand Down Expand Up @@ -194,7 +194,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">Symbol im Infobereich anzeigen</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">Maximal gespeicherte Einträge</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">Einträge löschen nach</Item>
<Item English_Text = "Days" ID = "2043">Tagen</Item>
<Item English_Text = "Minutes" ID = "2043">Minuten</Item>
<Item English_Text = "Compact and Repair" ID = "1028">Komprimieren und reparieren</Item>
<Item English_Text = "Automatically check for updates online" ID = "1029">Automatisch auf Updates prüfen</Item>
<Item English_Text = "Check Now" ID = "1030">Jetzt prüfen</Item>
Expand Down
2 changes: 1 addition & 1 deletion Debug/Language/Dutch.xml
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@
<Item English_Text = "Display Icon in Systeem Tray" ID = "2003">Toon pictogram in System Tray </Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">Maximum aantal opgeslagen clips</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">Opgeslagen clips vervallen na</Item>
<Item English_Text = "Days" ID = "2043">Dagen</Item>
<Item English_Text = "Minutes" ID = "2043">Minuten</Item>
<Item English_Text = "Compact and Repair" ID = "1028">Komprimeren en Repareren</Item>
<Item English_Text = "Check Now" ID = "1030">Check Nu</Item>
<Item English_Text = "Allow Duplicates" ID = "1037">Duplicaten toestaan</Item>
Expand Down
2 changes: 1 addition & 1 deletion Debug/Language/English.xml
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003"></Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008"></Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009"></Item>
<Item English_Text = "Days" ID = "2043"></Item>
<Item English_Text = "Minutes" ID = "2043"></Item>
<Item English_Text = "Compact and Repair" ID = "1028"></Item>
<Item English_Text = "Check Now" ID = "1030"></Item>
<Item English_Text = "Allow Duplicates" ID = "1037"></Item>
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/Finnish.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "1.1" Author = "Sami Kuusisto" Notes = "www.6sto.com" LanguageCode = "fin">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">Ryhmät</Item>
Expand Down Expand Up @@ -151,7 +151,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">Näytä kuvake järjestelmäpalkissa</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">Tallennettujen leikkeiden maksimimäärä</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">Poista leikkeet, kun aikaa kulunut</Item>
<Item English_Text = "Days" ID = "2043">Päivää</Item>
<Item English_Text = "Minutes" ID = "2043">Minuuttia</Item>
<Item English_Text = "Compact and Repair" ID = "1028">Pakkaa ja korjaa</Item>
<Item English_Text = "Check Now" ID = "1030">Tarkista nyt</Item>
<Item English_Text = "Allow Duplicates" ID = "1037">Salli duplikaatit</Item>
Expand Down
4 changes: 2 additions & 2 deletions Debug/Language/French.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<Ditto_Language_File Version = "1.5" Author = "Traduction originale de Alain AUPEIX (version 1), mise a jour, corrigee et completee par Simon PORTE et Largo" Notes = "Site de Alain AUPEIX : http://perso.wanadoo.fr/jujuland/" LanguageCode = "fre">
<Ditto_Right_Click_Menu>
<Item English_Text = "Groups" ID = "-1">Groupes</Item>
Expand Down Expand Up @@ -182,7 +182,7 @@
<Item English_Text = "Display Icon in System Tray" ID = "2003">Afficher l'icône dans la barre système</Item>
<Item English_Text = "Maximum Number of Saved Copies" ID = "2008">Nombre maxi de copies sauvegardées</Item>
<Item English_Text = "Paste Entries Expire after" ID = "2009">Les entrées de collage expirent après </Item>
<Item English_Text = "Days" ID = "2043">jours</Item>
<Item English_Text = "Minutes" ID = "2043">minutes</Item>
<Item English_Text = "Compact and Repair" ID = "1028">Compacter et Réparer la base</Item>
<Item English_Text = "Check Now" ID = "1030">Vérifier maintenant</Item>
<Item English_Text = "Allow Duplicates" ID = "1037">Autoriser les doublons</Item>
Expand Down
Loading