diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 3b18fb39b2f420..70630145ba3a66 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -48,7 +48,7 @@ jobs: bundle pristine ffi # END Dependencies - - name: Build Site + - name: Prepare Site Metadata run: | gem install bundler python -m pip install --upgrade pip @@ -62,6 +62,9 @@ jobs: curl --retry 5 https://gallantries.github.io/video-library/api/videos.json > metadata/video-library.json curl --retry 5 https://gallantries.github.io/video-library/api/sessions.json > metadata/session-library.json rdoc bin _plugins/ --output gtn_rdoc + + - name: Build Site + run: | JEKYLL_ENV=production bundle exec jekyll build --strict_front_matter -d _site/training-material cp metadata/feedback.csv _site/training-material/api/feedback.csv env: diff --git a/_plugins/jekyll-topic-filter.rb b/_plugins/jekyll-topic-filter.rb index 1310f9d97faeb8..534e93d26a433c 100644 --- a/_plugins/jekyll-topic-filter.rb +++ b/_plugins/jekyll-topic-filter.rb @@ -464,16 +464,16 @@ def self.resolve_material(site, material) all_resources = slides + tutorials page_obj['mod_date'] = all_resources - .map{|p| Gtn::ModificationTimes.obtain_time(p[1].path) } - .max + .map { |p| Gtn::ModificationTimes.obtain_time(p[1].path) } + .max page_obj['pub_date'] = all_resources - .map{|p| Gtn::PublicationTimes.obtain_time(p[1].path)} - .min + .map { |p| Gtn::PublicationTimes.obtain_time(p[1].path) } + .min page_obj['version'] = all_resources - .map{|p| Gtn::ModificationTimes.obtain_modification_count(p[1].path) } - .max + .map { |p| Gtn::ModificationTimes.obtain_modification_count(p[1].path) } + .max folder = material['dir'] diff --git a/bin/news.rb b/bin/news.rb index 3ee509e7772347..1d596d8b22779c 100755 --- a/bin/news.rb +++ b/bin/news.rb @@ -38,6 +38,10 @@ server: 'https://matrix.org', room: '!UQXYBSjdrLHcWgegmg:gitter.im', } + 'hub-social' => { + server: 'https://matrix.org', + room: '!gegHcnUCDklLbtVQor:matrix.org', + } } # rubocop:enable Style/GlobalVars # @@ -268,3 +272,4 @@ def send_news(output, options, channel: 'default') # GOATS: Rss/news only. output, newsworthy = build_news(data, only_news: true) send_news(output, options, channel: 'wg-goat') if newsworthy +send_news(output, options, channel: 'hub-social') if newsworthy diff --git a/bin/workflows-fetch.rb b/bin/workflows-fetch.rb index 959bde63f131a1..2aa95e38aa96b0 100755 --- a/bin/workflows-fetch.rb +++ b/bin/workflows-fetch.rb @@ -21,7 +21,7 @@ def request(url) def fetch_workflows(server) begin response = request("#{server}/api/workflows/") - rescue + rescue StandardError puts "ERROR: Failed to fetch workflows from #{server}" return [] end