nub 0.0.138 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +1 -83
- data/lib/nub/pacman.rb +1 -1
- metadata +3 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: adcad42f94888fef547b9228796aa260fd9935040556192d5f670e7f3c5d9abb
|
|
4
|
+
data.tar.gz: 59f5bc589fd108a672cf8913071366cb11c26a876ce23aeba2f3a2b0bc64e28a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 21802b97fd6a38bf151446ab2af0f9acd180ccdd16d3c881fc156f12f20a61ab2894629dbb0584a2967c183dd2861e070b8ceaa8b93129946cb8c1d4fc468b4e
|
|
7
|
+
data.tar.gz: b1bd14ebbe7e97a7a0ab51e9a4b6050cdcc1c4c4229783ac49af46f12b755a3b83537941aa2a485b085ff23be9be41bf38df858ce3d19778b28317a9a67eae97
|
data/README.md
CHANGED
|
@@ -6,7 +6,7 @@ Collection of ruby utils I've used in several of my projects and wanted re-usabl
|
|
|
6
6
|
[](https://coveralls.io/github/phR0ze/ruby-nub?branch=master&service=github)
|
|
7
7
|
[](https://opensource.org/licenses/MIT)
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
## Table of Contents
|
|
10
10
|
* [Deploy](#deploy)
|
|
11
11
|
* [Commander Module](#commander-module)
|
|
12
12
|
* [Commands](#commands)
|
|
@@ -40,14 +40,6 @@ Collection of ruby utils I've used in several of my projects and wanted re-usabl
|
|
|
40
40
|
* [Sys Module](#sys-module)
|
|
41
41
|
* [ThreadComm Module](#thread-comm-module)
|
|
42
42
|
* [User Module](#user-module)
|
|
43
|
-
* [Ruby Gem Creation](#ruby-gem-creation)
|
|
44
|
-
* [Package Layout](#package-layout)
|
|
45
|
-
* [Build Gem](#build-gem)
|
|
46
|
-
* [Install Gem](#install-gem)
|
|
47
|
-
* [Push Gem](#push-gem)
|
|
48
|
-
* [Integrate with Travis-CI](#integrate-with-travis-ci)
|
|
49
|
-
* [Install Travis Client](#install-travis-client)
|
|
50
|
-
* [Deploy Ruby Gem on Tag](#deploy-ruby-gem-on-tag)
|
|
51
43
|
|
|
52
44
|
## Deploy <a name="deploy"></a>
|
|
53
45
|
Run: `bundle install --system`
|
|
@@ -516,77 +508,3 @@ User.drop_privileges
|
|
|
516
508
|
# Raise privileges back to sudo user if previously dropped
|
|
517
509
|
User.raise_privileges
|
|
518
510
|
```
|
|
519
|
-
|
|
520
|
-
## Ruby Gem Creation <a name="ruby-gem-creation"></a>
|
|
521
|
-
http://guides.rubygems.org/make-your-own-gem/
|
|
522
|
-
|
|
523
|
-
This is my first ruby gem and am documenting what I did here
|
|
524
|
-
|
|
525
|
-
### Package Layout <a name="package-layout"></a>
|
|
526
|
-
All the ruby code will be in the sub directory ***lib***
|
|
527
|
-
|
|
528
|
-
* ***lib*** is where your gem's actual code should reside
|
|
529
|
-
* ***nub.gemspec*** is your interface to RubyGems.org all the data provided here is used by the gem
|
|
530
|
-
repo
|
|
531
|
-
|
|
532
|
-
### Build Gem <a name="build-gem"></a>
|
|
533
|
-
```
|
|
534
|
-
gem build nub.gemspec
|
|
535
|
-
```
|
|
536
|
-
|
|
537
|
-
### Install Gem <a name="install-gem"></a>
|
|
538
|
-
```
|
|
539
|
-
gem install nub-0.0.1.gem
|
|
540
|
-
```
|
|
541
|
-
|
|
542
|
-
### Push Gem <a name="push-gem"></a>
|
|
543
|
-
Once you've built and tested your gem and are happy with it push it to RubyGems.org
|
|
544
|
-
|
|
545
|
-
```bash
|
|
546
|
-
# Download your user credentials
|
|
547
|
-
curl -u phR0ze https://rubygems.org/api/v1/api_key.yaml > ~/.gem/credentials
|
|
548
|
-
# Enter host password for user 'phR0ze':
|
|
549
|
-
# Revoke read permission from everyone but you
|
|
550
|
-
chmod og-r ~/.gem/credentials
|
|
551
|
-
# Push gem
|
|
552
|
-
gem push nub-0.0.1.gem
|
|
553
|
-
# List out your gems takes about a min
|
|
554
|
-
gem list -r nub
|
|
555
|
-
```
|
|
556
|
-
|
|
557
|
-
## Integrate with Travis-CI <a name="integrate-with-travis-ci"></a>
|
|
558
|
-
Example project https://github.com/Integralist/Sinderella
|
|
559
|
-
|
|
560
|
-
### Install Travis Client <a name="install-travis-client"></a>
|
|
561
|
-
```bash
|
|
562
|
-
sudo gem install travis --no-user-install
|
|
563
|
-
```
|
|
564
|
-
|
|
565
|
-
### Deploy Ruby Gem on Tag <a name="deploy-ruby-gem-on-tag"></a>
|
|
566
|
-
Create the file ***.travis.yml***
|
|
567
|
-
|
|
568
|
-
* Using ***cache: bundler*** builds the dependencies once and then reuses them in future builds.
|
|
569
|
-
* Script ***rake*** is actually the default for ***ruby*** but calling it out for clarity to run unit tests
|
|
570
|
-
* Deploying using the ***rubygems*** provider on tags
|
|
571
|
-
|
|
572
|
-
```yaml
|
|
573
|
-
language: ruby
|
|
574
|
-
sudo: false
|
|
575
|
-
cache: bundler
|
|
576
|
-
rvm:
|
|
577
|
-
- 2.5.0
|
|
578
|
-
before_install:
|
|
579
|
-
- gem update --system
|
|
580
|
-
script:
|
|
581
|
-
- rake
|
|
582
|
-
deploy:
|
|
583
|
-
provider: rubygems
|
|
584
|
-
api_key:
|
|
585
|
-
secure: <encrypted key>
|
|
586
|
-
gem: nub
|
|
587
|
-
on:
|
|
588
|
-
tags: true
|
|
589
|
-
notifications:
|
|
590
|
-
email: false
|
|
591
|
-
```
|
|
592
|
-
|
data/lib/nub/pacman.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: nub
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.1.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Patrick Crummett
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2019-03-06 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: colorize
|
|
@@ -121,8 +121,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
121
121
|
- !ruby/object:Gem::Version
|
|
122
122
|
version: '0'
|
|
123
123
|
requirements: []
|
|
124
|
-
|
|
125
|
-
rubygems_version: 2.7.7
|
|
124
|
+
rubygems_version: 3.0.3
|
|
126
125
|
signing_key:
|
|
127
126
|
specification_version: 4
|
|
128
127
|
summary: Collection of useful utilities
|