-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathaction.yml
More file actions
99 lines (87 loc) · 2.79 KB
/
Copy pathaction.yml
File metadata and controls
99 lines (87 loc) · 2.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
name: 'Setup Subversion'
description: 'Set up Apache Subversion (svn) command line tool'
branding:
icon: 'download'
color: 'blue'
inputs:
svn-version:
description: 'Version of Subversion to install (default: latest available from package manager)'
required: false
default: ''
outputs:
svn-version:
description: 'The installed version of Subversion'
value: ${{ steps.svn-info.outputs.version }}
runs:
using: 'composite'
steps:
- name: Install Subversion on Ubuntu/Debian
if: runner.os == 'Linux'
shell: bash
run: |
sudo apt-get update
sudo apt-get install -y subversion
- name: Install Subversion on macOS
if: runner.os == 'macOS'
shell: bash
run: |
brew install subversion
- name: Install Subversion on Windows
if: runner.os == 'Windows'
shell: pwsh
run: |
choco install -y sliksvn
- name: Add Subversion to PATH on Windows
if: runner.os == 'Windows'
shell: pwsh
run: |
# Find Subversion installation directory
$possiblePaths = @(
"C:\Program Files (x86)\SlikSvn\bin",
"C:\Program Files\SlikSvn\bin",
"C:\Program Files (x86)\Subversion\bin",
"C:\Program Files\Subversion\bin"
)
$svnPath = $null
foreach ($path in $possiblePaths) {
if (Test-Path $path) {
$svnPath = $path
break
}
}
if ($svnPath) {
echo "Found Subversion at: $svnPath"
echo "$svnPath" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
# Verify files exist
$svnExe = Join-Path $svnPath "svn.exe"
$svnadminExe = Join-Path $svnPath "svnadmin.exe"
echo "svn.exe exists: $(Test-Path $svnExe)"
echo "svnadmin.exe exists: $(Test-Path $svnadminExe)"
} else {
echo "ERROR: Could not find Subversion installation directory"
echo "Searched paths:"
foreach ($path in $possiblePaths) {
echo " - $path (exists: $(Test-Path $path))"
}
exit 1
}
- name: Verify installation and get version
id: svn-info
shell: bash
run: |
svn --version --quiet
echo "version=$(svn --version --quiet)" >> $GITHUB_OUTPUT
- name: Verify svnadmin is available
shell: bash
run: |
svnadmin --version
- name: Display Subversion info
shell: bash
run: |
echo "Subversion installed successfully!"
echo "Commands available: svn, svnadmin, svnlook, svnsync, svnrdump, svnserve, svnversion, svnmucc"
echo ""
svn --version
echo ""
echo "svn location: $(which svn || where svn)"
echo "svnadmin location: $(which svnadmin || where svnadmin)"