The package rpms/nodejs-meow.git has added or updated architecture specific content in
its
spec file (ExclusiveArch/ExcludeArch or %ifarch/%ifnarch) in commit(s):
https://src.fedoraproject.org/cgit/rpms/nodejs-meow.git/commit/?id=e42e8e....
Change:
+ExclusiveArch: %{nodejs_arches} noarch
Thanks.
Full change:
============
commit e42e8e29551c6f03bd6060a0e7b999b6ffb9ec0f
Author: Jared K. Smith <jaredsmith(a)jaredsmith.net>
Date: Wed May 24 18:43:03 2017 -0400
Initial packaging
diff --git a/.gitignore b/.gitignore
index e69de29..6e1e31c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/meow-3.7.0.tgz
diff --git a/fixture.js b/fixture.js
new file mode 100644
index 0000000..08de81c
--- /dev/null
+++ b/fixture.js
@@ -0,0 +1,27 @@
+{
+ foo: "bar 'bar'",
+ foo2: [
+ "foo",
+ "bar",
+ {
+ foo: "bar 'bar'"
+ }
+ ],
+ "foo-foo": "bar",
+ "2foo": "bar",
+ "@#": "bar",
+ $el: "bar",
+ _private: "bar",
+ number: 1,
+ boolean: true,
+ date: new Date('2014-01-29T22:41:05.665Z'),
+ escapedString: "\"\"",
+ null: null,
+ undefined: undefined,
+ function: function () {},
+ regexp: /./,
+ NaN: NaN,
+ Infinity: Infinity,
+ newlines: "foo\nbar\r\nbaz",
+ circular: "[Circular]"
+}
diff --git a/nodejs-meow.spec b/nodejs-meow.spec
new file mode 100644
index 0000000..6cae05f
--- /dev/null
+++ b/nodejs-meow.spec
@@ -0,0 +1,86 @@
+%{?nodejs_find_provides_and_requires}
+
+%global packagename meow
+%global enable_tests 0
+# tests disabled due to missing npm(ava) test suite
+
+Name: nodejs-meow
+Version: 3.7.0
+Release: 2%{?dist}
+Summary: CLI app helper
+
+License: MIT
+URL:
https://github.com/sindresorhus/meow
+Source0:
https://registry.npmjs.org/%{packagename}/-/%{packagename}-%{version}.tgz
+# The test files are not included in the npm tarball.
+Source1:
https://raw.githubusercontent.com/sindresorhus/meow/v%{version}/test.js
+Source2:
https://raw.githubusercontent.com/sindresorhus/meow/v%{version}/fixture.js
+
+
+ExclusiveArch: %{nodejs_arches} noarch
+BuildArch: noarch
+
+BuildRequires: nodejs-packaging
+BuildRequires: npm(camelcase-keys)
+BuildRequires: npm(decamelize)
+BuildRequires: npm(loud-rejection)
+BuildRequires: npm(minimist)
+BuildRequires: npm(object-assign)
+BuildRequires: npm(read-pkg-up)
+BuildRequires: npm(redent)
+BuildRequires: npm(trim-newlines)
+%if 0%{?enable_tests}
+BuildRequires: npm(ava)
+BuildRequires: npm(normalize-package-data)
+%endif
+
+%description
+CLI app helper
+
+
+%prep
+%setup -q -n package
+# setup the tests
+cp -p %{SOURCE1} .
+cp -p %{SOURCE2} .
+
+%nodejs_fixdep camelcase-keys
+%nodejs_fixdep redent
+%nodejs_fixdep read-pkg-up
+
+%build
+# nothing to do!
+
+%install
+mkdir -p %{buildroot}%{nodejs_sitelib}/%{packagename}
+cp -pr package.json *.js \
+ %{buildroot}%{nodejs_sitelib}/%{packagename}
+
+%nodejs_symlink_deps
+
+%check
+%nodejs_symlink_deps --check
+%{__nodejs} -e 'require("./")'
+%if 0%{?enable_tests}
+%{_bindir}/ava
+%else
+%{_bindir}/echo -e "\e[101m -=#=- Tests disabled -=#=- \e[0m"
+%endif
+
+%files
+%{!?_licensedir:%global license %doc}
+%doc *.md
+%license license
+%{nodejs_sitelib}/%{packagename}
+
+
+
+%changelog
+* Thu Apr 20 2017 Jared Smith <jsmith(a)fedoraproject.org> - 3.7.0-2
+- Allow newer version of npm(read-pkg-up)
+
+* Fri Jul 15 2016 Jared Smith <jsmith(a)fedoraproject.org> - 3.7.0-1
+- Update to upstream 3.7.0 release
+
+* Thu Oct 29 2015 Jared Smith <jsmith(a)fedoraproject.org> - 3.4.2-1
+- Initial packaging
diff --git a/sources b/sources
index e69de29..1dd42a3 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+SHA512 (meow-3.7.0.tgz) =
4cd77066cd2c9119693e90942b6e52b42e151feb4fe4681e6351d038e18ffa5436c6d76437656d4ffe6d897f64dc85a99013d5f5bdcbb005979f81868bf3eb48
diff --git a/test.js b/test.js
new file mode 100644
index 0000000..27fd3ce
--- /dev/null
+++ b/test.js
@@ -0,0 +1,71 @@
+import test from 'ava';
+import indentString from 'indent-string';
+import execa from 'execa';
+import pkg from './package.json';
+import fn from './';
+
+global.Promise = Promise;
+
+test('return object', t => {
+ const cli = fn({
+ argv: ['foo', '--foo-bar', '-u', 'cat'],
+ help: [
+ 'Usage',
+ ' foo <input>'
+ ]
+ }, {
+ alias: {u: 'unicorn'},
+ default: {meow: 'dog'}
+ });
+
+ t.is(cli.input[0], 'foo');
+ t.true(cli.flags.fooBar);
+ t.is(cli.flags.meow, 'dog');
+ t.is(cli.flags.unicorn, 'cat');
+ t.is(cli.pkg.name, 'meow');
+ t.is(cli.help, indentString('\nCLI app helper\n\nUsage\n foo <input>',
' '));
+});
+
+test('support help shortcut', t => {
+ const cli = fn(['unicorn', 'cat']);
+ t.is(cli.help, indentString('\nCLI app helper\n\nunicorn\ncat', ' '));
+});
+
+test('spawn cli and show version', async t => {
+ const {stdout} = await execa('./fixture.js', ['--version']);
+
+ t.is(stdout, pkg.version);
+});
+
+test('spawn cli and show help screen', async t => {
+ const {stdout} = await execa('./fixture.js', ['--help']);
+
+ t.is(stdout, indentString('\nCustom description\n\nUsage\n foo <input>',
' '));
+});
+
+test('spawn cli and test input', async t => {
+ const {stdout} = await execa('./fixture.js', ['-u', 'cat']);
+
+ t.is(stdout, 'u\nunicorn\nmeow\ncamelCaseOption');
+});
+
+test('spawn cli and test input', async t => {
+ const {stdout} = await execa('./fixture.js', ['--camel-case-option',
'bar']);
+
+ t.is(stdout, 'bar');
+});
+
+test.serial('pkg.bin as a string should work', t => {
+ fn({
+ pkg: {
+ name: 'browser-sync',
+ bin: 'bin/browser-sync.js'
+ }
+ });
+
+ t.is(process.title, 'browser-sync');
+});
+
+test('single character flag casing should be preserved', t => {
+ t.ok(fn({argv: ['-F']}).flags.F);
+});