Skip to content
Merged
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
2 changes: 2 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ jobs:
-
name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
Expand Down
6 changes: 4 additions & 2 deletions _plugins/fetch_remote.rb
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ def self.resolve_line_numbers(first, last)
def pre_read(site)
beginning_time = Time.now
puts "Starting plugin fetch_remote.rb..."

fetch_depth = get_docs_url == "http://localhost:4000" ? 1 : 0
site.config['fetch-remote'].each do |entry|
puts " Repo #{entry['repo']}"

Expand All @@ -55,11 +57,11 @@ def pre_read(site)
rescue => e
FileUtils.rm_rf(clonedir)
puts " Cloning repository into #{clonedir}"
git = Git.clone("#{entry['repo']}.git", Pathname.new(clonedir), branch: entry['ref'], depth: 1)
git = Git.clone("#{entry['repo']}.git", Pathname.new(clonedir), branch: entry['ref'], depth: fetch_depth)
end
else
puts " Cloning repository into #{clonedir}"
git = Git.clone("#{entry['repo']}.git", Pathname.new(clonedir), branch: entry['ref'], depth: 1)
git = Git.clone("#{entry['repo']}.git", Pathname.new(clonedir), branch: entry['ref'], depth: fetch_depth)
end

entry['paths'].each do |path|
Expand Down