Skip to content

Commit cc8caec

Browse files
authored
Merge pull request #1660 from adsingh14/auto-download-setup
Remove windows-setup auto download functionality
2 parents 02815ce + 3e5f50d commit cc8caec

File tree

3 files changed

+28
-67
lines changed

3 files changed

+28
-67
lines changed

app/assets/javascripts/application.js

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -238,17 +238,6 @@ var Downloads = {
238238
Downloads.observeGUIOSFilter();
239239
Downloads.observePopState();
240240
Downloads.filterGUIS();
241-
Downloads.triggerAutoDownload();
242-
},
243-
244-
triggerAutoDownload: function() {
245-
var ref = document.referrer;
246-
var src = $('#auto-download-link').attr('href');
247-
248-
if (this.shouldAutoDownload(ref, src)) {
249-
$('.downloading .hide').show();
250-
document.location = src;
251-
}
252241
},
253242

254243
shouldAutoDownload: function(ref, src) {

app/assets/stylesheets/downloads.scss

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -38,29 +38,6 @@
3838
}
3939
}
4040

41-
.callout.downloading {
42-
background: $callout-color url("/images/icons/download.png") 24px 24px no-repeat;
43-
padding: 20px 30px 20px 100px !important;
44-
45-
h3 {
46-
font-size: 18px;
47-
color: $orange;
48-
}
49-
50-
p {
51-
margin-bottom: 15px !important;
52-
font-size: 15px;
53-
line-height: 1.3em;
54-
}
55-
56-
p.small {
57-
margin-bottom: 0 !important;
58-
font-size: 12px;
59-
line-height: 1.4;
60-
color: $light-font-color;
61-
}
62-
}
63-
6441
#download-next-steps {
6542
@include clearfix;
6643
@extend .unstyled !optional;

app/views/downloads/download_windows.html.erb

Lines changed: 28 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -7,39 +7,34 @@
77
<% end %>
88

99
<div id="main">
10-
<h1>Downloading Git</h1>
11-
<div class="callout downloading">
12-
<h3 class="hide">Your download is starting...</h3>
13-
<p>
14-
<%= raw "You are downloading the latest (<strong>#{@download.version.name}</strong>) <strong>#{@bitness}</strong> version of <strong>Git for Windows</strong>. This is the most recent <a href='#{@project_url}'>maintained build</a>. It was released <strong>#{time_ago_in_words @download.release_date} ago</strong>, on #{@download.release_date.strftime("%Y-%m-%d")}." %>
15-
</p>
16-
<p>
17-
<%= raw "<strong><a id=\"auto-download-link\" href=\"#{@download.url}\">Click here to download manually</a><span class=\"hide\">, if your download hasn't started.</span></strong>" %>
18-
</p>
19-
<h3>Other Git for Windows downloads</h3>
20-
<h4>Executable Setup</h4>
21-
<p>
22-
<%= raw "<strong><a href=\"#{@download32.url}\">32-bit Git for Windows Setup</a>.</strong>" %>
23-
</p>
24-
<p>
25-
<%= raw "<strong><a href=\"#{@download64.url}\">64-bit Git for Windows Setup</a>.</strong>" %>
26-
</p>
27-
<h4>Portable ("thumbdrive edition")</h4>
28-
<p>
29-
<%= raw "<strong><a href=\"#{@download32portable.url}\">32-bit Git for Windows Portable</a>.</strong>" %>
30-
</p>
31-
<p>
32-
<%= raw "<strong><a href=\"#{@download64portable.url}\">64-bit Git for Windows Portable</a>.</strong>" %>
33-
</p>
34-
<h4>Using winget tool</h4>
35-
<p>
36-
Install <a href="https://docs.microsoft.com/en-us/windows/package-manager/winget">winget tool</a> if you don't already have it, then type this command in command prompt or Powershell.<br>
37-
<code>winget install --id Git.Git -e --source winget</code>
38-
</p>
39-
<p class="small">
40-
<%= raw "The current source code release is version <strong>#{@latest.name}</strong>. If you want the newer version, you can build it from <a href=\"#{@source_url}\">the source code</a>." %>
41-
</p>
42-
</div>
10+
<h1>Download for Windows</h1>
11+
<p>
12+
<%= raw "<strong><a id=\"auto-download-link\" href=\"#{@download.url}\">Click here to download </a></strong>" %><%= raw " the latest (<strong>#{@download.version.name}</strong>) <strong>#{@bitness}</strong> version of <strong>Git for Windows</strong>. This is the most recent <a href='#{@project_url}'>maintained build</a>. It was released <strong>#{time_ago_in_words @download.release_date} ago</strong>, on #{@download.release_date.strftime("%Y-%m-%d")}." %>
13+
</p>
14+
<h3>Other Git for Windows downloads</h3>
15+
<h4>Standalone Installer</h4>
16+
<p>
17+
<%= raw "<strong><a href=\"#{@download32.url}\">32-bit Git for Windows Setup</a>.</strong>" %>
18+
</p>
19+
<p>
20+
<%= raw "<strong><a href=\"#{@download64.url}\">64-bit Git for Windows Setup</a>.</strong>" %>
21+
</p>
22+
<h4>Portable ("thumbdrive edition")</h4>
23+
<p>
24+
<%= raw "<strong><a href=\"#{@download32portable.url}\">32-bit Git for Windows Portable</a>.</strong>" %>
25+
</p>
26+
<p>
27+
<%= raw "<strong><a href=\"#{@download64portable.url}\">64-bit Git for Windows Portable</a>.</strong>" %>
28+
</p>
29+
<h4>Using winget tool</h4>
30+
<p>
31+
Install <a href="https://docs.microsoft.com/en-us/windows/package-manager/winget">winget tool</a> if you don't already have it, then type this command in command prompt or Powershell.<br>
32+
<code>winget install --id Git.Git -e --source winget</code>
33+
</p>
34+
<p class="small">
35+
<%= raw "The current source code release is version <strong>#{@latest.name}</strong>. If you want the newer version, you can build it from <a href=\"#{@source_url}\">the source code</a>." %>
36+
</p>
37+
4338
<h2>Now What?</h2>
4439
<p>
4540
Now that you have downloaded Git, it's time to start using it.

0 commit comments

Comments
 (0)