Compare commits

...
Sign in to create a new pull request.

80 commits

Author SHA1 Message Date
Dominik 'Rathann' Mierzejewski
838fb1a9ee updated to 2.0.26 (resolves rhbz#2265214)
- droped upstreamed patches
2025-12-15 13:10:36 +01:00
Mamoru TASAKA
3d7bae2b69 Add logger dep for ruby3_5 2025-11-05 23:11:47 +09:00
Fedora Release Engineering
75de982163 Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild 2025-07-25 12:16:36 +00:00
Fedora Release Engineering
fd4e80e38f Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild 2025-01-18 22:58:59 +00:00
Mamoru TASAKA
1b5b583b1a Backport upstream PR to remove base64 dependency
Backport upstream fix for ruby34 formatting change
2024-11-14 16:33:39 +09:00
Fedora Release Engineering
468fa4fa10 Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild 2024-07-19 19:03:32 +00:00
Fedora Release Engineering
7300f0454d Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-26 16:34:50 +00:00
Fedora Release Engineering
334f9c42aa Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-22 12:28:57 +00:00
Mamoru TASAKA
4e8fb62bfb Apply the upstream PR to support ruby 3.3 Logger 2023-09-29 15:23:35 +09:00
Fedora Release Engineering
91ff5bc8e0 Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-07-21 17:20:40 +00:00
Todd Zullinger
22023dba55 improve ruby-2.5 compatibility (epel8)
An unfortunate bug in rdoc-5.0 causes a build failure on epel8.  This is
fixed in ruby-2.6/rdoc-6.0.2¹.  Until/unless the fix is backported to
RHEL-8 (which seems unlikely), we can only patch around this.

Thanks, as usual, to Dan Allen for going above and beyond to patch this
upstream.

¹ https://github.com/ruby/rdoc/pull/586
  a1631aa
2023-05-26 13:25:46 -04:00
Todd Zullinger
bd6465f42a update to asciidoctor 2.0.20 (rhbz#2208089)
Release notes:
https://github.com/asciidoctor/asciidoctor/releases/tag/v2.0.20
2023-05-18 08:44:45 -04:00
Todd Zullinger
f73db33c50 update to asciidoctor 2.0.19 (rhbz#2208089)
Release notes:
https://github.com/asciidoctor/asciidoctor/releases/tag/v2.0.19
2023-05-17 21:02:46 -04:00
Todd Zullinger
24ce10d5c7 fixes for ruby-3.2.x and rouge-4.1.0 (rhbz#2171711)
Apply upstream fixes for ruby >= 3.2.0rc1¹ and rouge >= 4.1².

Many thanks to Dan Allen for fixing these issues in very short order!

¹ https://github.com/asciidoctor/asciidoctor/issues/4390
² https://github.com/asciidoctor/asciidoctor/issues/4406
2023-02-21 13:16:44 -05:00
Todd Zullinger
01966d7434 verify SPDX license identifier
According to https://tools.spdx.org/app/check_license/ the contents of
the LICENSE file match the MIT SPDX ID.
2023-02-13 17:05:53 -05:00
Fedora Release Engineering
50b3fbb819 Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-01-20 20:11:14 +00:00
Todd Zullinger
4c7660f922 update to asciidoctor 2.0.18 (rhbz#1989716)
Release notes:
https://github.com/asciidoctor/asciidoctor/releases/tag/v2.0.18
2022-10-15 11:50:10 -04:00
Todd Zullinger
8a5e9a406b update to asciidoctor 2.0.17 (rhbz#2113688, FTBFS)
The 2.0.17 release includes fixes for some tests which fail with ruby
3.1.

It also adds some new tests which require the open-uri-cached gem.
Disable those tests until open-uri-cached is packaged.

Helped-by: Michael J Gruber <mjg@fedoraproject.org>
2022-08-07 14:05:42 -04:00
Fedora Release Engineering
d1d7163f3c Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-07-23 01:17:17 +00:00
Neal Gompa
3442759132 Simplify RHEL conditionals 2022-01-21 06:38:20 -05:00
Fedora Release Engineering
8280e909de - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-07-23 11:49:57 +00:00
Todd Zullinger
ef9b17fa0b remove el6 conditionals
EL-6 ended support in November, 2020.  Drop the remaining conditional
checks which reference it.
2021-04-27 20:43:57 -04:00
Todd Zullinger
70d458cc2d Update to Asciidoctor 2.0.15
Release notes:
https://github.com/asciidoctor/asciidoctor/releases/tag/v2.0.15
2021-04-27 20:41:55 -04:00
Todd Zullinger
b13d03746d Update to Asciidoctor 2.0.14
Release notes:
https://github.com/asciidoctor/asciidoctor/releases/tag/v2.0.14
2021-04-19 14:26:24 -04:00
Todd Zullinger
01da4053ee remove upstreamed erubi patch
The patch which added erubi template engine support was released 2.0.12.
Remove the stale patch file.
2021-04-19 14:24:31 -04:00
Todd Zullinger
614cb70e6d Update to Asciidoctor 2.0.13
Release notes:
https://github.com/asciidoctor/asciidoctor/releases/tag/v2.0.13
2021-04-10 19:54:40 -04:00
Pavel Valena
00da97c840 Update to asciidoctor 2.0.12.
Resolves: rhbz#1893940
2021-01-28 04:04:03 +01:00
Pavel Valena
1f2c7cb1de Do not run tests for any %{rhel} distros. 2021-01-28 04:00:37 +01:00
Fedora Release Engineering
3994ba328c - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-01-27 15:39:19 +00:00
Vít Ondruch
4f30337ed5 Remove build time Erubis dependency. 2020-09-15 09:45:28 +02:00
Fedora Release Engineering
f4c2b9f8fc - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-07-29 06:08:02 +00:00
Fedora Release Engineering
bc090a2e45 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-01-30 18:07:55 +00:00
Todd Zullinger
deb557b413 Update to Asciidoctor 2.0.10
The distributed gem file no longer contains the tests, so we now
download a tarball via the git tag.  While adjusting Source0, update the
URL to point to the main asciidoc home page.

Release notes:
https://github.com/asciidoctor/asciidoctor/releases/tag/v2.0.10
2019-09-22 10:40:43 -04:00
Fedora Release Engineering
0652b980a0 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-07-26 19:00:26 +00:00
Todd Zullinger
5c9f250572 Add rpmlint config
Ignore warnings about spelling and the missing asciidoctor-safe manpage.
Upstream removed the asciidoctor-safe command in 6dfaaed8 ("remove
asciidoctor-safe binary", 2019-02-05).
2019-03-19 23:13:34 -04:00
Todd Zullinger
e40dad145d Update to Asciidoctor 1.5.8
In addition to many enhancements, fixes, and improvements, this release
resolves a denial of service issue (CVE-2018-18385)¹.

The LICENSE file was renamed, a German translation of the README was
added, and concurrent-ruby replaced thread_safe.

Release notes:
https://github.com/asciidoctor/asciidoctor/releases/tag/v1.5.8

¹ https://github.com/asciidoctor/asciidoctor/issues/2888
2019-03-19 22:53:41 -04:00
Todd Zullinger
bbbd682424 Remove repository README.adoc
Pagure does not support asciidoc format.  The result is a largely
unreadable pile of text.
2019-03-19 22:53:41 -04:00
Todd Zullinger
6717e68cbb Simplify and improve git ignore rules
Using a pattern to match the source .gem files prevents fedpkg upload
from needlessly appending each new source file to .gitignore.

Also ignore *.rpm, logs from 'fedpkg local' builds, the 'fedpkg
mockbuild' results dir, and expanded source directories.
2019-03-19 13:26:55 -04:00
Todd Zullinger
78d8329fe9 Fix typos when skipping asciimath tests
s/avaiable/available/
2019-03-19 13:26:55 -04:00
Todd Zullinger
0737548057 Remove stale comments about missing test suite parts
Parts of the test suite were missing in the official 1.5.5 release.
This was addressed in 62c46b2 ("Fix FTBFS.", 2017-06-05) and fixed
upstream in fd602b75 ("include entire test suite in gem (PR #1952)",
2016-11-29).  The 1.5.6 release included that fix, but the comment
remained after 46fa0bd ("Update to 1.5.6.1", 2017-08-24).
2019-03-19 12:03:12 -04:00
Fedora Release Engineering
6eee24f6b7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-02-02 11:49:12 +00:00
Igor Gnatenko
d3a6d07131 Remove obsolete Group tag
References: https://fedoraproject.org/wiki/Changes/Remove_Group_Tag
2019-01-28 20:24:46 +01:00
Zbigniew Jędrzejewski-Szmek
bf11e2146b Use C.UTF-8 locale 2018-11-19 00:23:05 +01:00
Fedora Release Engineering
3766a32a95 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2018-07-14 03:53:46 +00:00
Vít Ondruch
10fa9bcac8 Enable entire test suite. 2018-05-24 07:32:13 +02:00
Fedora Release Engineering
53bc01f6bc - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2018-02-09 13:33:47 +00:00
Fabio Alessandro Locati
46fa0bdeb9
Update to 1.5.6.1 2017-08-24 13:44:46 +02:00
Fedora Release Engineering
a8d2025c2a - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild 2017-07-27 13:26:20 +00:00
Vít Ondruch
62c46b252b Fix FTBFS. 2017-06-05 15:28:32 +02:00
Fedora Release Engineering
51935fc48f - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild 2017-02-11 12:00:15 +00:00
Fabio Alessandro Locati
799834f208
Fix email 2017-01-09 20:11:50 +01:00
Fabio Alessandro Locati
963b494e9a Update to 1.5.5 2016-10-27 23:50:55 +02:00
Fedora Release Engineering
90ffac9243 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild 2016-02-04 22:28:29 +00:00
Ken Dreyer
d6c93927cd Update to Asciidoctor 1.5.4 (rhbz#1295758)
- Use %license macro
- Drop unnecessary "-p" flag to cp during %install ("-a" already
  preserves timestamps)
2016-01-06 10:05:03 -07:00
Ken Dreyer
ff6e2a42c6 Update to Asciidoctor 1.5.3
Resolves: rhbz#1276851

Changelog:
- Update to Asciidoctor 1.5.3 (rhbz#1276851)
- Drop Fedora 19 and 20 macros (these distros are EOL)
2015-11-02 11:59:05 -07:00
Dennis Gilmore
aa1d22dca5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild 2015-06-18 22:45:48 +00:00
Dan Allen
15f7252312 cleanup .gitignore 2015-05-13 15:16:52 -06:00
Dan Allen
2740c8aefd drop tests and test dependencies in EPEL build 2015-05-13 15:13:52 -06:00
Dan Allen
9cac499bb6 update README
- update version of Asciidoctor
- use modern AsciiDoc syntax
2015-05-11 15:28:56 -06:00
Ken Dreyer
ea9461a140 Update to Asciidoctor 1.5.2 2014-12-05 14:33:37 -07:00
Ken Dreyer
bb913a459f Update to Asciidoctor 1.5.1 2014-09-19 07:48:18 -06:00
Ken Dreyer
79e247f5f1 correct 1.5.0 version number in changelog 2014-09-19 07:45:27 -06:00
Ken Dreyer
aa6ac2843b Update to 1.5.0 final
Reported-by: Jonathan Bullock <jonbullock@gmail.com>
2014-09-09 10:09:20 -06:00
Ken Dreyer
ffc7e9fb9a Add %{version} number to Provides: asciidoctor 2014-06-05 21:16:35 -06:00
Ken Dreyer
11883bf59c Provide: asciidoctor
https://github.com/asciidoctor/rubygem-asciidoctor-rpm/issues/5
2014-06-05 21:02:08 -06:00
Ken Dreyer
5dbaa5a481 Update to Asciidoctor 0.1.5.preview.7
- Drop unused patch
2014-05-19 21:03:39 -06:00
Ken Dreyer
cbd79bbfe7 Update to Asciidoctor 0.1.5.preview.6
- Use HTTPS URLs
- Support Minitest 5
- Adjustments for https://fedoraproject.org/wiki/Changes/Ruby_2.1
- Mark CHANGELOG, LICENSE, READMEs as %doc
- Remove Rakefile in %prep
- Remove Requires: /usr/bin/env
2014-05-15 18:27:16 -06:00
Ken Dreyer
bfa997cc2a add spacing to changelog 2014-05-15 17:18:01 -06:00
Vít Ondruch
eec8217490 Execute test suite using minitest 4.x. 2014-04-14 13:46:57 +02:00
Dan Allen
b042612fcd add info about srpm in koji 2013-09-23 16:16:37 -06:00
Dan Allen
711459a7c2 remove srpm 2013-09-23 16:13:40 -06:00
Dan Allen
5551a14d24 update srpm from koji 2013-09-22 19:07:23 -06:00
Dan Allen
c05c0100aa remove test for including content from a URI 2013-09-22 18:24:49 -06:00
Dan Allen
6354126026 change include uri test to use non-https URI 2013-09-22 18:11:29 -06:00
Dan Allen
ceeaf60583 resolves #4 upgrade package to Asciidoctor 0.1.4 2013-09-22 17:40:13 -06:00
Dennis Gilmore
91ccc3c4c7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild 2013-08-04 08:26:10 -05:00
Dan Allen
072ea2a31c remove old gem 2013-06-08 23:22:39 -06:00
Dan Allen
0b95935d26 add srpm for 0.1.3 2013-06-08 16:39:06 -06:00
Dan Allen
03da4579e1 remove old srpm 2013-06-08 16:31:08 -06:00
Dan Allen
5bde1e294e update 0.1.3 gem signature 2013-06-08 16:30:09 -06:00
8 changed files with 277 additions and 262 deletions

6
.gitignore vendored
View file

@ -1 +1,5 @@
/asciidoctor-0.1.3.gem
/*.rpm
/*.tar.gz
/.build*.log
/asciidoctor-*/
/results_*/

View file

@ -1,197 +0,0 @@
= rubygem-asciidoctor: Asciidoctor RPM package spec
Dan Allen
:idprefix:
:gem_title: Asciidoctor
:gem_name: asciidoctor
:gem_version: 0.1.3
:gem_gem: {gem_name}-{gem_version}.gem
:gem_url: https://github.com/asciidoctor/asciidoctor
:rpm_name: rubygem-{gem_name}
:rpm_rpm: {rpm_name}-{gem_version}.rpm
:rpm_repo: git://github.com/asciidoctor/rubygem-asciidoctor-rpm.git
This repository is the official host of the build materials to create the Fedora RPM package for the https://github.com/asciidoctor/asciidoctor[Asciidoctor] RubyGem.
The package is named +rubygem-asciidoctor+.
While this RPM spec was developed specifically for Fedora 17 and above, it may be useful for other RPM-based systems.
== Build the Asciidoctor RPM
If you want to build the RPM on your own machine, follow the instructions in this section.
If you want to test a pre-built package, skip to the next section on <<test-the-asciidoctor-rpm-and-report-feedback,testing the RPM>>.
=== Preparing your environment
You first need to install the packages necessary to build the RPM.
Begin by installing the +@fedora-packager+ group (as root or using sudo):
yum install @fedora-packager wget
Next, clone this repository and switch to it:
git clone git://github.com/asciidoctor/rubygem-asciidoctor-rpm.git
cd rubygem-asciidoctor-rpm
Finally, install the packages that this build requires (as root or using sudo):
yum-builddep rubygem-asciidoctor.spec
Next, we need to put the package source and patches in place.
=== Preparing the sources
You can build RPMs as a non-privileged user, though you need to prepare the directories first.
Let's use the directory rpmbuild in our +$HOME+ directory:
echo "%_topdir %(echo $HOME)/rpmbuild" > $HOME/.rpmmacros
You'll also need to create all the required folders:
mkdir -p $HOME/rpmbuild/{BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS}
Next, grab the Asciidoctor gem (the sources) and put it into the +$HOME/rpmbuild/SOURCES+ directory:
wget -O $HOME/rpmbuild/SOURCES/asciidoctor-0.1.3.gem http://rubygems.org/gems/asciidoctor-0.1.3.gem
Finally, copy the +.patch+ files from this repository to the same directory:
cp *.patch $HOME/rpmbuild/SOURCES/
You're now ready to build the RPM.
=== Building the RPM
With everything in place, building the RPM is easy!
rpmbuild -ba rubygem-asciidoctor.spec
If all goes well, both the binary and source RPMs will emerge in the +$HOME/rpmbuild/RPMS/noarch+ and +$HOME/rpmbuild/SRPMS+ directories, respectively.
=== Installing the RPM
There's nothing special about installing this RPM.
I recommend using +yum+ because it will install any dependencies that the package requires (though you should already have them if you built the RPM).
yum localinstall $HOME/rpmbuild/RPMS/noarch/rubygem-asciidoctor-0.1.3.rpm
Now, it's time to start using Asciidoctor!
== Test the Asciidoctor RPM and report feedback
Before the Asciidoctor package (+rubygem-asciidoctor+) can be included in the Fedora distribution, it must be tested by users and receive karma via the http://admin.fedoraproject.org/updates[Bohdi system].
One way to provide this feedback is to use the http://admin.fedoraproject.org/pkgdb/acls/name/fedora-easy-karma[fedora-easy-karma] tool.
=== Enable the updates-testing repository temporarily
In a terminal, type:
sudo yum install rubygem-asciidoctor --enablerepo=updates-testing
This command will download and install the asciidoctor package.
=== Test the Asciidoctor package: +rubygem-asciidoctor+
First, let's test using Asciidoctor as a Ruby library.
. On your computer, create a new file and name it +asciidoctor-test.rb+
. Copy and paste the following code into the file:
require 'asciidoctor'
content = "= My First Document\n\nRender me some **HTML**!"
puts Asciidoctor.render(content, :header_footer => true, :compact => true)
. Save the file.
. In a terminal, navigate to the directory where you saved +asciidoctor-test.rb+ and type the following command to execute the file with Ruby:
ruby asciidoctor-test.rb
+
You should see this output in your terminal.
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="generator" content="Asciidoctor 0.1.3">
<title>My First Document</title>
</head>
<body class="article">
<div id="header">
<h1>My First Document</h1>
</div>
<div id="content">
<div id="preamble">
<div class="sectionbody">
<div class="paragraph">
<p>Render me some <strong>HTML</strong>!</p>
</div>
</div>
</div>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2013-03-12 10:43:15 MDT
</div>
</div>
</body>
</html>
. You can render the output as HTML using:
ruby asciidoctor-test.rb > asciidoctor-test.html
. Open your browser to see the result.
. Alternatively, if you're using Gnome, type:
gnome-open asciidoctor-test.html
+
A new tab should open in your current browser session.
Now let's test using the Asciidoctor executable.
. On your computer, create a new file and name it +test.ad+
. Copy and paste the following markup into the file:
= My Second Document
Your Name
AsciiDoc is _rockin'_ docs.
. Save the file
. In a terminal, navigate to the directory where you saved +test.ad+ and type the following command to run it through the Asciidoctor processor:
asciidoctor test.ad
+
You shouldn't see any output in your terminal.
That's because it writes the output to the file +test.html+.
. Open your browser to see the result.
. Alternatively, if you're using Gnome, type:
gnome-open test.html
+
A new tab should open in your current browser session.
=== Provide feedback with fedora-easy-karma
. If you don't have fedora-easy-karma installed on your computer, type the following command in a terminal.
sudo yum install fedora-easy-karma
. Once fedora-easy-karma is installed, run it in the terminal.
fedora-easy-karma --fas-username <yourFASaccount> *asciidoctor
+
To be on the safe side, include the flag for your FAS account when you start fedora-easy-karma.
Once fedora-easy-karma runs, you will not be able to switch accounts.
+
NOTE: It may take fedora-easy-karma several minutes to fetch the list of packages in updates-testing.
+
When fedora-easy-karma finds +rubygem-asciidoctor+, it will display a summary of the package and prompt you to give -1 (negative), 0 (neutral), or 1 (postive) karma to the package.
For more information about providing karma for packages and how to comment on packages, review the http://fedoraproject.org/wiki/QA:Update_feedback_guidelines[Fedora feedback guidelines].
. Enter your karma rating.
. Next, you will be asked to provide additional, detailed feedback.
Please comment whether the package worked as expected and you successfully used it, if you think you may have encountered an error, but aren't sure, or if you definitely encountered a bug.
. When prompted, enter your FAS password.
. W00t! The feedback process is complete.
. You can verify your feedback was recorded by visiting the https://admin.fedoraproject.org/updates[Bodhi updates page].

View file

@ -1,16 +0,0 @@
# disables use of pending statement in the test suite The required gem,
# pending, is not packaged in Fedora and since the statement is merely a task
# note, it's safe to disable it's usage for the purpose of packaging.
diff --git a/test/test_helper.rb b/test/test_helper.rb
index 3b27218..964ff59 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -5,7 +5,7 @@ require 'test/unit'
require "#{File.expand_path(File.dirname(__FILE__))}/../lib/asciidoctor.rb"
require 'nokogiri'
-require 'pending'
+#require 'pending'
ENV['SUPPRESS_DEBUG'] ||= 'true'

View file

@ -0,0 +1,7 @@
from Config import *
# the dictionary is a bit limited
addFilter("rubygem-asciidoctor\..*: W: spelling-error %description -l en_US toolchain")
# the asciidoctor-safe command is removed upstream for the next major release
addFilter("rubygem-asciidoctor\..*: W: no-manual-page-for-binary asciidoctor-safe")

View file

@ -1,44 +1,57 @@
%global gem_name asciidoctor
%global mandir %{_mandir}/man1
Summary: AsciiDoc implementation in Ruby
%define pre %nil
%global gittag v%{version}%{pre}
Summary: A fast, open source AsciiDoc implementation in Ruby
Name: rubygem-%{gem_name}
Version: 0.1.3
Version: 2.0.26
Release: 1%{?dist}
Group: Development/Languages
License: MIT
URL: http://github.com/asciidoctor/asciidoctor
Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem
# Patch0: disables use of pending statement in the test suite The required gem,
# pending, is not packaged in Fedora and since the statement is merely a task
# note, it's safe to disable it's usage for the purpose of packaging.
Patch0: asciidoctor-disable-use-of-pending.patch
%if 0%{?rhel} > 6 || 0%{?fedora} > 18
URL: https://asciidoctor.org
Source0: https://github.com/asciidoctor/asciidoctor/archive/%{gittag}/%{gem_name}-%{version}%{pre}.tar.gz
%if 0%{?el7}
Requires: ruby(release)
BuildRequires: ruby(release)
%else
Requires: ruby(abi) = 1.9.1
BuildRequires: ruby(abi) = 1.9.1
%endif
Requires: ruby(rubygems)
BuildRequires: rubygems-devel
BuildRequires: ruby(rubygems)
%if ! 0%{?rhel}
# Dependencies aren't available on EPEL
BuildRequires: rubygem(coderay)
BuildRequires: rubygem(erubis)
BuildRequires: rubygem(concurrent-ruby)
BuildRequires: rubygem(erubi)
BuildRequires: rubygem(haml)
BuildRequires: rubygem(logger)
BuildRequires: rubygem(minitest)
BuildRequires: rubygem(nokogiri)
BuildRequires: rubygem(rouge)
BuildRequires: rubygem(slim)
BuildRequires: rubygem(tilt)
%endif
BuildArch: noarch
Provides: asciidoctor = %{version}
%if 0%{?el7}
Provides: rubygem(%{gem_name}) = %{version}
%endif
%if %{?pre:1}
%global gem_instdir() %{gem_dir}/gems/%{gem_name}-%{version}%{pre}
%global gem_cache %{gem_dir}/cache/%{gem_name}-%{version}%{pre}.gem
%global gem_spec %{gem_dir}/specifications/%{gem_name}-%{version}%{pre}.gemspec
%global gem_docdir %{gem_dir}/doc/%{gem_name}-%{version}%{pre}
%endif
%description
An open source text processor and publishing toolchain written in Ruby for
converting AsciiDoc markup into HTML 5, DocBook 4.5 and custom formats. Export
to custom formats is performed by running the nodes of the parsed tree through
a collection of Tilt-supported templates.
A fast, open source text processor and publishing toolchain, written in Ruby,
for transforming AsciiDoc markup into HTML 5, DocBook 4.5, DocBook 5.0 and
custom output formats. The transformation from AsciiDoc to custom output
formats is performed by running the nodes in the parsed document tree through a
collection of templates written in a template language supported by Tilt.
%package doc
Summary: Documentation for %{name}
Group: Documentation
Requires: %{name} = %{version}-%{release}
BuildArch: noarch
@ -46,59 +59,259 @@ BuildArch: noarch
Documentation for %{name}
%prep
gem unpack -V %{SOURCE0}
%setup -q -D -T -n %{gem_name}-%{version}
gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
%patch0 -p1
%autosetup -n %{gem_name}-%{version}%{pre} -p1
# Include tests in the gem, they're disabled by default
sed -i -e 's/#\(s\.test_files\)/\1/' %{gem_name}.gemspec
# Fix shebang (avoid Requires: /usr/bin/env)
sed -i -e 's|#!/usr/bin/env ruby|#!/usr/bin/ruby|' bin/%{gem_name}
# ref: https://github.com/asciidoctor/asciidoctor/issues/4684
# the upstream plans to remove logger dep, but for now
# add logger dep explicitly for ruby3_5
%gemspec_add_dep -g logger -s ./%{gem_name}.gemspec
%build
gem build %{gem_name}.gemspec
%gem_install
%gem_install -n %{gem_name}-%{version}%{pre}.gem
%check
LANG=en_US.utf8 testrb -Ilib test/*_test.rb
pushd .%{gem_instdir}
%if ! 0%{?rhel}
# Asciidoctor tests require Minitest 5, so we can't run them on EPEL
#
# disable tests which require open-uri-cached gem
sed -Ei "/test 'should cache remote (SVG|image) when allow-uri-read, cache-uri, and (inline option|data-uri) are set' do/a \\
skip('open-uri-cached gem is not avaiable on Fedora')" test/blocks_test.rb
LANG=C.UTF-8 ruby -I"lib:test" -e 'Dir.glob "./test/**/*_test.rb", &method(:require)'
%endif
popd
%install
mkdir -p %{buildroot}%{gem_dir}
cp -pa .%{gem_dir}/* \
%{buildroot}%{gem_dir}/
cp -a .%{gem_dir}/* \
%{buildroot}%{gem_dir}/
mkdir -p %{buildroot}%{_bindir}
cp -pa .%{_bindir}/* \
%{buildroot}%{_bindir}/
cp -a .%{_bindir}/* \
%{buildroot}%{_bindir}/
mkdir -p %{buildroot}%{mandir}
cp -pa .%{gem_instdir}/man/*.1 \
%{buildroot}%{mandir}/
mkdir -p %{buildroot}%{_sysconfdir}/%{gem_name}
cp -pa .%{gem_instdir}/compat/* \
%{buildroot}%{_sysconfdir}/%{gem_name}/
cp -a .%{gem_instdir}/man/*.1 \
%{buildroot}%{mandir}/
%files
%dir %{gem_instdir}
%exclude %{gem_cache}
%exclude %{gem_instdir}/%{gem_name}.gemspec
%exclude %{gem_instdir}/Gemfile
%exclude %{gem_instdir}/Guardfile
%exclude %{gem_instdir}/Rakefile
%exclude %{gem_instdir}/compat
%exclude %{gem_instdir}/asciidoctor.gemspec
%exclude %{gem_instdir}/man
%exclude %{gem_instdir}/test
%{gem_instdir}/LICENSE
%{gem_instdir}/README.*
%exclude %{gem_instdir}/features
%license %{gem_instdir}/LICENSE
%doc %{gem_instdir}/CHANGELOG.adoc
%doc %{gem_instdir}/README.*
%lang(de) %doc %{gem_instdir}/README-de.*
%lang(fr) %doc %{gem_instdir}/README-fr.*
%lang(ja) %doc %{gem_instdir}/README-jp.*
%lang(zh_CN) %doc %{gem_instdir}/README-zh_CN.*
%{gem_instdir}/data
%{_bindir}/*
%{gem_instdir}/bin
%{gem_libdir}
%{mandir}/*
%{_sysconfdir}/%{gem_name}/*
%{gem_spec}
%files doc
%doc %{gem_docdir}
%changelog
* Mon Dec 15 2025 Dominik Mierzejewski <dominik@greysector.net> - 2.0.26-1
- updated to 2.0.26 (resolves rhbz#2265214)
- droped upstreamed patches
* Wed Nov 05 2025 Mamoru TASAKA <mtasaka@fedoraproject.org> - 2.0.20-11
- Add logger dep for ruby3_5
* Fri Jul 25 2025 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.20-10
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
* Sat Jan 18 2025 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.20-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
* Thu Nov 14 2024 Mamoru TASAKA <mtasaka@fedoraproject.org> - 2.0.20-8
- Backport upstream PR to remove base64 dependency
- Backport upstream fix for ruby34 formatting change
* Fri Jul 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.20-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
* Fri Jan 26 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.20-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Mon Jan 22 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.20-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Sep 29 2023 Mamoru TASAKA <mtasaka@fedoraproject.org> - 2.0.20-4
- Apply the upstream PR to support ruby 3.3 Logger
* Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.20-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Thu May 25 2023 Todd Zullinger <tmz@pobox.com> - 2.0.20-2
- improve ruby-2.5 compatibility (epel8)
* Thu May 18 2023 Todd Zullinger <tmz@pobox.com> - 2.0.20-1
- update to asciidoctor 2.0.20 (rhbz#2208089)
* Wed May 17 2023 Todd Zullinger <tmz@pobox.com> - 2.0.19-1
- update to asciidoctor 2.0.19 (rhbz#2208089)
* Mon Feb 20 2023 Todd Zullinger <tmz@pobox.com> - 2.0.18-3
- fixes for ruby-3.2.x and rouge-4.1.0 (rhbz#2171711)
* Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.18-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Sat Oct 15 2022 Todd Zullinger <tmz@pobox.com> - 2.0.18-1
- update to asciidoctor 2.0.18 (rhbz#1989716)
* Tue Aug 02 2022 Todd Zullinger <tmz@pobox.com> - 2.0.17-1
- update to asciidoctor 2.0.17 (rhbz#2113688)
- disable tests which require open-uri-cached gem
* Sat Jul 23 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.15-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Fri Jan 21 2022 Neal Gompa <ngompa@fedoraproject.org> - 2.0.15-3
- Simplify RHEL conditionals
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.15-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Tue Apr 27 2021 Todd Zullinger <tmz@pobox.com> - 2.0.15-1
- update to asciidoctor 2.0.15
Resolves: rhbz#1954314
- remove el6 conditionals
* Mon Apr 19 2021 Todd Zullinger <tmz@pobox.com> - 2.0.14-1
- Update to asciidoctor 2.0.14
Resolves: rhbz#1950947
* Sat Apr 10 2021 Todd Zullinger <tmz@pobox.com> - 2.0.13-1
- Update to asciidoctor 2.0.13
Resolves: rhbz#1948231
* Wed Jan 27 2021 Pavel Valena <pvalena@redhat.com> - 2.0.12-1
- Update to asciidoctor 2.0.12.
Resolves: rhbz#1893940
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.10-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Wed Aug 19 2020 Vít Ondruch <vondruch@redhat.com> - 2.0.10-4
- Replace build time Erubis dependency by Erubi.
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.10-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.10-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
* Sun Sep 22 2019 Todd Zullinger <tmz@pobox.com> - 2.0.10-1
- Update to Asciidoctor 2.0.10
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.8-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Tue Mar 19 2019 Todd Zullinger <tmz@pobox.com> - 1.5.8-1
- Update to Asciidoctor 1.5.8 (resolves CVE-2018-18385)
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.6.1-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Sun Nov 18 2018 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.5.6.1-5
- Use C.UTF-8 locale
See https://fedoraproject.org/wiki/Changes/Remove_glibc-langpacks-all_from_buildroot
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.6.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Wed May 23 2018 Vít Ondruch <vondruch@redhat.com> - 1.5.6.1-3
- Enable entire test suite.
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.6.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
* Thu Aug 24 2017 Fabio Alessandro Locati <fale@fedoraproject.org> - 1.5.6.1-1
- Update to Asciidoctor 1.5.6.1
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.5-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
* Mon Jun 05 2017 Vít Ondruch <vondruch@redhat.com> - 1.5.5-2
- Fix FTBFS.
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.5-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
* Fri Oct 14 2016 Fabio Alessandro Locati <fale@fedoraproject.org> - 1.5.5-1
- Update to Asciidoctor 1.5.5
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.4-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
* Tue Jan 05 2016 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.4-1
- Update to Asciidoctor 1.5.4 (rhbz#1295758)
- Use %%license macro
- Drop unnecessary "-p" flag to cp during %%install ("-a" already preserves
timestamps)
* Mon Nov 02 2015 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.3-1
- Update to Asciidoctor 1.5.3 (rhbz#1276851)
- Drop Fedora 19 and 20 macros (these distros are EOL)
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.5.2-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
* Fri Dec 05 2014 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.2-1
- Update to Asciidoctor 1.5.2
* Fri Sep 19 2014 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.1-1
- Update to Asciidoctor 1.5.1
* Tue Sep 09 2014 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.0-1
- Update to Asciidoctor 1.5.0 final
* Fri Jun 06 2014 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.0-0.4.preview.7
- Add %%{version} number to Provides: asciidoctor
* Fri Jun 06 2014 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.0-0.3.preview.7
- Provide: asciidoctor
https://github.com/asciidoctor/rubygem-asciidoctor-rpm/issues/5
* Tue May 20 2014 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.0-0.2.preview.7
- Update to Asciidoctor 0.1.5.preview.7
- Drop unused patch
* Thu May 15 2014 Ken Dreyer <ktdreyer@ktdreyer.com> - 1.5.0-0.1.preview.6
- Update to Asciidoctor 0.1.5.preview.6
- Use HTTPS URLs
- Support Minitest 5
- Adjustments for https://fedoraproject.org/wiki/Changes/Ruby_2.1
- Mark CHANGELOG, LICENSE, READMEs as %%doc
- Remove Rakefile in %%prep
- Remove Requires: /usr/bin/env
* Sun Sep 22 2013 Dan Allen <dan.j.allen@gmail.com> - 0.1.4-1
- Update to Asciidoctor 0.1.4
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
* Sat Jun 08 2013 Dan Allen <dan.j.allen@gmail.com> - 0.1.3-1
- Update to Asciidoctor 0.1.3
* Fri Mar 01 2013 Dan Allen <dan.j.allen@gmail.com> - 0.1.1-1
- Initial package

View file

@ -1 +1 @@
e5a9d0015ea477589d5da1765df0d834 asciidoctor-0.1.1.gem
SHA512 (asciidoctor-2.0.26.tar.gz) = 5e42079374fb1767dd0fd6767fd1e718d2c1c673e131ef1ae401c7b17e5b413168de3b25889eda35d2021ded55855b83b78f6110729e1a7765f757b37bbf5858

View file

@ -6,10 +6,14 @@ require 'asciidoctor'
source = <<EOS
= Asciidoctor
Author Name
Author Name <author@example.com>
http://asciidoctor.org[Asciidoctor] is an _open source_ implementation of
http://asciidoc.org[AsciiDoc] in [red]*Ruby*.
http://asciidoc.org[AsciiDoc] in [.red]*Ruby*.
== Sample section
Sample section content
EOS
puts Asciidoctor.render(source, :backend => :html5, :header_footer => true, :compact => true, :safe => :safe, :attributes => 'linkcss!')
puts Asciidoctor.render(source, :backend => :html5, :header_footer => true, :safe => :safe, :attributes => 'idprefix= idseparator=-')