mirror of
https://github.com/XcodesOrg/XcodesApp.git
synced 2026-03-25 08:55:46 +00:00
Build and publish appcasts with GitHub Pages
This commit is contained in:
parent
c2482d6740
commit
7cb94f5dd6
8 changed files with 235 additions and 0 deletions
27
.github/workflows/appcast.yml
vendored
Normal file
27
.github/workflows/appcast.yml
vendored
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
name: Build and publish a new appcast file
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
release:
|
||||
|
||||
jobs:
|
||||
jekyll:
|
||||
runs-on: ubuntu-16.04
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/cache@v2
|
||||
with:
|
||||
path: vendor/bundle
|
||||
key: ${{ runner.os }}-gems-v1.0-${{ hashFiles('AppCast/Gemfile') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-gems-
|
||||
|
||||
- uses: helaili/jekyll-action@v2
|
||||
env:
|
||||
JEKYLL_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
gem_src: 'AppCast'
|
||||
jekyll_src: 'AppCast'
|
||||
target_branch: 'gh-pages'
|
||||
3
AppCast/.gitignore
vendored
Normal file
3
AppCast/.gitignore
vendored
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
_site
|
||||
.sass-cache
|
||||
.jekyll-metadata
|
||||
28
AppCast/Gemfile
Normal file
28
AppCast/Gemfile
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
source "https://rubygems.org"
|
||||
|
||||
# Hello! This is where you manage which Jekyll version is used to run.
|
||||
# When you want to use a different version, change it below, save the
|
||||
# file and run `bundle install`. Run Jekyll with `bundle exec`, like so:
|
||||
#
|
||||
# bundle exec jekyll serve
|
||||
#
|
||||
# This will help ensure the proper Jekyll version is running.
|
||||
# Happy Jekylling!
|
||||
gem "jekyll", "~> 3.9.0"
|
||||
|
||||
gem "jekyll-github-metadata", group: :jekyll_plugins
|
||||
|
||||
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
|
||||
# and associated library.
|
||||
install_if -> { RUBY_PLATFORM =~ %r!mingw|mswin|java! } do
|
||||
gem "tzinfo", "~> 1.2"
|
||||
gem "tzinfo-data"
|
||||
end
|
||||
|
||||
# Performance-booster for watching directories on Windows
|
||||
gem "wdm", "~> 0.1.0", :install_if => Gem.win_platform?
|
||||
|
||||
# kramdown v2 ships without the gfm parser by default. If you're using
|
||||
# kramdown v1, comment out this line.
|
||||
gem "kramdown-parser-gfm"
|
||||
|
||||
92
AppCast/Gemfile.lock
Normal file
92
AppCast/Gemfile.lock
Normal file
|
|
@ -0,0 +1,92 @@
|
|||
GEM
|
||||
remote: https://rubygems.org/
|
||||
specs:
|
||||
addressable (2.7.0)
|
||||
public_suffix (>= 2.0.2, < 5.0)
|
||||
colorator (1.1.0)
|
||||
concurrent-ruby (1.1.7)
|
||||
em-websocket (0.5.2)
|
||||
eventmachine (>= 0.12.9)
|
||||
http_parser.rb (~> 0.6.0)
|
||||
eventmachine (1.2.7)
|
||||
faraday (1.3.0)
|
||||
faraday-net_http (~> 1.0)
|
||||
multipart-post (>= 1.2, < 3)
|
||||
ruby2_keywords
|
||||
faraday-net_http (1.0.1)
|
||||
ffi (1.14.2)
|
||||
forwardable-extended (2.6.0)
|
||||
http_parser.rb (0.6.0)
|
||||
i18n (0.9.5)
|
||||
concurrent-ruby (~> 1.0)
|
||||
jekyll (3.9.0)
|
||||
addressable (~> 2.4)
|
||||
colorator (~> 1.0)
|
||||
em-websocket (~> 0.5)
|
||||
i18n (~> 0.7)
|
||||
jekyll-sass-converter (~> 1.0)
|
||||
jekyll-watch (~> 2.0)
|
||||
kramdown (>= 1.17, < 3)
|
||||
liquid (~> 4.0)
|
||||
mercenary (~> 0.3.3)
|
||||
pathutil (~> 0.9)
|
||||
rouge (>= 1.7, < 4)
|
||||
safe_yaml (~> 1.0)
|
||||
jekyll-github-metadata (2.13.0)
|
||||
jekyll (>= 3.4, < 5.0)
|
||||
octokit (~> 4.0, != 4.4.0)
|
||||
jekyll-sass-converter (1.5.2)
|
||||
sass (~> 3.4)
|
||||
jekyll-watch (2.2.1)
|
||||
listen (~> 3.0)
|
||||
kramdown (2.3.0)
|
||||
rexml
|
||||
kramdown-parser-gfm (1.1.0)
|
||||
kramdown (~> 2.0)
|
||||
liquid (4.0.3)
|
||||
listen (3.4.1)
|
||||
rb-fsevent (~> 0.10, >= 0.10.3)
|
||||
rb-inotify (~> 0.9, >= 0.9.10)
|
||||
mercenary (0.3.6)
|
||||
multipart-post (2.1.1)
|
||||
octokit (4.20.0)
|
||||
faraday (>= 0.9)
|
||||
sawyer (~> 0.8.0, >= 0.5.3)
|
||||
pathutil (0.16.2)
|
||||
forwardable-extended (~> 2.6)
|
||||
public_suffix (4.0.6)
|
||||
rb-fsevent (0.10.4)
|
||||
rb-inotify (0.10.1)
|
||||
ffi (~> 1.0)
|
||||
rexml (3.2.4)
|
||||
rouge (3.26.0)
|
||||
ruby2_keywords (0.0.2)
|
||||
safe_yaml (1.0.5)
|
||||
sass (3.7.4)
|
||||
sass-listen (~> 4.0.0)
|
||||
sass-listen (4.0.0)
|
||||
rb-fsevent (~> 0.9, >= 0.9.4)
|
||||
rb-inotify (~> 0.9, >= 0.9.7)
|
||||
sawyer (0.8.2)
|
||||
addressable (>= 2.3.5)
|
||||
faraday (> 0.8, < 2.0)
|
||||
thread_safe (0.3.6)
|
||||
tzinfo (1.2.9)
|
||||
thread_safe (~> 0.1)
|
||||
tzinfo-data (1.2020.6)
|
||||
tzinfo (>= 1.0.0)
|
||||
wdm (0.1.1)
|
||||
|
||||
PLATFORMS
|
||||
x86_64-darwin-20
|
||||
|
||||
DEPENDENCIES
|
||||
jekyll (~> 3.9.0)
|
||||
jekyll-github-metadata
|
||||
kramdown-parser-gfm
|
||||
tzinfo (~> 1.2)
|
||||
tzinfo-data
|
||||
wdm (~> 0.1.0)
|
||||
|
||||
BUNDLED WITH
|
||||
2.2.5
|
||||
36
AppCast/_config.yml
Normal file
36
AppCast/_config.yml
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
# Welcome to Jekyll!
|
||||
#
|
||||
# This config file is meant for settings that affect your whole blog, values
|
||||
# which you are expected to set up once and rarely edit after that. If you find
|
||||
# yourself editing this file very often, consider using Jekyll's data files
|
||||
# feature for the data you need to update frequently.
|
||||
#
|
||||
# For technical reasons, this file is *NOT* reloaded automatically when you use
|
||||
# 'bundle exec jekyll serve'. If you change this file, please restart the server process.
|
||||
|
||||
# Site settings
|
||||
# These are used to personalize your new site. If you look in the HTML files,
|
||||
# you will see them accessed via {{ site.title }}, {{ site.email }}, and so on.
|
||||
# You can create any custom variable you would like, and they will be accessible
|
||||
# in the templates via {{ site.myvariable }}.
|
||||
title: Xcodes.app
|
||||
description: >- # this means to ignore newlines until "baseurl:"
|
||||
baseurl: "" # the subpath of your site, e.g. /blog
|
||||
url: "" # the base hostname & protocol for your site, e.g. http://example.com
|
||||
|
||||
# Build settings
|
||||
markdown: kramdown
|
||||
plugins:
|
||||
- "jekyll-github-metadata"
|
||||
|
||||
# Exclude from processing.
|
||||
# The following items will not be processed, by default. Create a custom list
|
||||
# to override the default setting.
|
||||
# exclude:
|
||||
# - Gemfile
|
||||
# - Gemfile.lock
|
||||
# - node_modules
|
||||
# - vendor/bundle/
|
||||
# - vendor/cache/
|
||||
# - vendor/gems/
|
||||
# - vendor/ruby/
|
||||
41
AppCast/_includes/appcast.inc
Normal file
41
AppCast/_includes/appcast.inc
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<rss version="2.0" xmlns:sparkle="http://www.andymatuschak.org/xml-namespaces/sparkle" xmlns:dc="http://purl.org/dc/elements/1.1/">
|
||||
<channel>
|
||||
<title>{{ site.github.project_title }}</title>
|
||||
<description>Most recent changes with links to updates.</description>
|
||||
<language>en</language>
|
||||
{% for release in site.github.releases %}
|
||||
{% unless release.draft %}
|
||||
{% unless release.prerelease and page.release_only %}
|
||||
<item>
|
||||
<title>{{ release.name }}</title>
|
||||
<description><![CDATA[{{ release.body | markdownify }}]]></description>
|
||||
<pubDate>{{ release.published_at | date_to_rfc822 }}</pubDate>
|
||||
{% for asset in release.assets limit:1 %}
|
||||
{% assign build_nums = release.tag_name | replace_first:'v','' | replace_first:'b',',' | split:',' %}
|
||||
{% if build_nums.size == 2 %}
|
||||
{% assign version_number = build_nums[0] %}
|
||||
{% assign build_number = build_nums[1] %}
|
||||
|
||||
<enclosure
|
||||
url="{{ asset.browser_download_url }}"
|
||||
sparkle:version="{{ build_number }}"
|
||||
sparkle:shortVersionString="{{ version_number }}"
|
||||
length="{{ asset.size }}"
|
||||
type="application/octet-stream" />
|
||||
{% else %}
|
||||
{% assign version = release.tag_name | remove_first:'v' %}
|
||||
|
||||
<enclosure
|
||||
url="{{ asset.browser_download_url }}"
|
||||
sparkle:version="{{ version }}"
|
||||
length="{{ asset.size }}"
|
||||
type="application/octet-stream" />
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</item>
|
||||
{% endunless %}
|
||||
{% endunless %}
|
||||
{% endfor %}
|
||||
</channel>
|
||||
</rss>
|
||||
4
AppCast/appcast.xml
Normal file
4
AppCast/appcast.xml
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
---
|
||||
release_only: true
|
||||
---
|
||||
{%include appcast.inc %}
|
||||
4
AppCast/appcast_pre.xml
Normal file
4
AppCast/appcast_pre.xml
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
---
|
||||
release_only: false
|
||||
---
|
||||
{%include appcast.inc %}
|
||||
Loading…
Reference in a new issue