kajian-kajian_muslim 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: e695a9f55c2a07e555816598dab8bd0a569261e7
4
+ data.tar.gz: adb094d4f02c53c7ef1a4475ce34c9ee607b6858
5
+ SHA512:
6
+ metadata.gz: 3959f8d65823b625ade203fdf19cb18ee58d19e41982118de5873f6e0329ac330103921253f7a9cda9e8e9324bfefcea99605b5cc1d87649688ba71ff9df1739
7
+ data.tar.gz: 3f1719e3b651c8ea40f38d4184bc4d2977aed2c172b866d533a32cd79a840204f6fd6313ad2b8cb0f44f01f289a9ce3f457593a2ec22a500afefd2223c6de996
@@ -0,0 +1,9 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
data/Gemfile ADDED
@@ -0,0 +1,16 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in kajian-kajian_muslim.gemspec
4
+ gemspec
5
+
6
+ gem 'nokogiri', '~> 1.8'
7
+ gem 'kajian', '~> 0.1'
8
+
9
+ group :development do
10
+ gem 'bundler', '~> 1.14'
11
+ gem 'rake', '~> 12.1'
12
+ end
13
+
14
+ group :development, :test do
15
+ gem 'pry', '~> 0.10'
16
+ end
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2017 Adrian Setyadi
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
@@ -0,0 +1,39 @@
1
+ # Kajian::Adapter::KajianMuslim
2
+
3
+ Plugin/Adapter pustaka [kajian](https://github.com/styd/kajian) untuk situs
4
+ [Kajian Muslim](https://kajianmuslim.com)
5
+
6
+ ## Pemasangan
7
+
8
+ Tambahkan baris berikut ini pada Gemfile Anda:
9
+
10
+ ```ruby
11
+ gem 'kajian'
12
+ gem 'kajian-kajian_muslim'
13
+ ```
14
+
15
+ Lalu jalankan:
16
+
17
+ $ bundle
18
+
19
+ Atau Anda pasang sendiri seperti ini:
20
+
21
+ $ gem install kajian kajian-kajian_muslim
22
+
23
+ ## Penggunaan
24
+
25
+ ```ruby
26
+ require 'kajian'
27
+ require 'kajian/adapter/kajian_muslim'
28
+
29
+ Kajian.lihat(:kajian_muslim).bekasi
30
+ ```
31
+
32
+ ## TODO
33
+
34
+ * Tambahkan data untuk `waktu`.
35
+
36
+ ## Lisensi
37
+
38
+ Gem ini tersedia sebagai _open source_ sesuai ketentuan
39
+ [MIT License](http://opensource.org/licenses/MIT).
@@ -0,0 +1,2 @@
1
+ require "bundler/gem_tasks"
2
+ task :default => :spec
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "kajian/kajian_muslim"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ require "irb"
14
+ IRB.start(__FILE__)
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,17 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+
5
+ Gem::Specification.new do |spec|
6
+ spec.name = "kajian-kajian_muslim"
7
+ spec.version = "0.1.0"
8
+ spec.author = "Adrian Setyadi"
9
+ spec.email = "adrian@setyadi.pro"
10
+ spec.summary = %q{Plugin/Adapter untuk pustaka Kajian.}
11
+ spec.homepage = "https://github.com/styd/kajian-kajian_muslim"
12
+ spec.license = "MIT"
13
+ spec.files = `git ls-files -z`.split("\x0").reject do |f|
14
+ f.match(%r{^(test|spec|features)/})
15
+ end
16
+ spec.require_paths = ["lib"]
17
+ end
@@ -0,0 +1,58 @@
1
+ {
2
+ "malang": "/malang/",
3
+ "surabaya": "/surabaya/",
4
+ "jakarta": "/jakarta/",
5
+ "sidoarjo": "/sidoarjo/",
6
+ "lamongan": "/lamongan/",
7
+ "tangerang": "/tangerang/",
8
+ "yogyakarta": "/yogyakarta/",
9
+ "bandung": "/bandung/",
10
+ "kediri": "/kediri/",
11
+ "pontianak": "/pontianak/",
12
+ "bondowoso": "/bondowoso/",
13
+ "batu": "/batu/",
14
+ "nganjuk": "/nganjuk/",
15
+ "bogor": "/bogor/",
16
+ "gresik": "/gresik/",
17
+ "ponorogo": "/ponorogo/",
18
+ "jombang": "/jombang/",
19
+ "bekasi": "/bekasi/",
20
+ "mojokerto": "/mojokerto/",
21
+ "lumajang": "/lumajang/",
22
+ "cirebon": "/cirebon/",
23
+ "jember": "/jember/",
24
+ "banjarmasin": "/banjarmasin/",
25
+ "blitar": "/blitar/",
26
+ "balikpapan": "/balikpapan/",
27
+ "lampung": "/lampung/",
28
+ "pekalongan": "/pekalongan/",
29
+ "garut": "/garut/",
30
+ "samarinda": "/samarinda/",
31
+ "bali": "/bali/",
32
+ "cikarang": "/cikarang/",
33
+ "surakarta": "/surakarta/",
34
+ "pekanbaru": "/pekanbaru/",
35
+ "bangkalan": "/bangkalan/",
36
+ "pacitan": "/pacitan/",
37
+ "pasuruan": "/pasuruan/",
38
+ "magetan": "/magetan/",
39
+ "trenggalek": "/trenggalek/",
40
+ "situbondo": "/situbondo/",
41
+ "tulungagung": "/tulungagung/",
42
+ "bintaro": "/bintaro/",
43
+ "cianjur": "/cianjur/",
44
+ "semarang": "/semarang/",
45
+ "medan": "/medan/",
46
+ "lombok_timur": "/lombok-timur/",
47
+ "deli_serdang": "/deli-serdang/",
48
+ "kendari": "/kendari/",
49
+ "purbalingga": "/purbalingga/",
50
+ "denpasar": "/denpasar/",
51
+ "purwokerto": "/purwokerto/",
52
+ "langsa": "/langsa/",
53
+ "cimahi": "/cimahi/",
54
+ "padang": "/padang/",
55
+ "cibubur": "/cibubur/",
56
+ "ngawi": "/ngawi/",
57
+ "kertosoono": "/kertosoono/"
58
+ }
@@ -0,0 +1,31 @@
1
+ require 'kajian/makro'
2
+
3
+ module Kajian
4
+ class Adapter
5
+ class KajianMuslim
6
+ extend Kajian::Makro
7
+
8
+ @url = 'https://kajianmuslim.com/kota'
9
+
10
+ @direktori_master = json_ke_hash("#{simbol}.json")
11
+
12
+ blok(css: '.kajian-container')
13
+
14
+ tema(
15
+ css: '.kajian-title-val',
16
+ hilangkan: /^(Hadirilah|Ikutilah)?\s+/
17
+ )
18
+
19
+ penceramah(css: '.kajian-ustadz li a')
20
+
21
+ tempat do |blok|
22
+ blok.css('strong.kajian-location-val').text +
23
+ "\n" + blok.css('span.kajian-addr-val').text
24
+ end
25
+
26
+ tanggal(css: '.kajian-date-thumb', parser: Date)
27
+
28
+ gambar(css: 'a.poster img')
29
+ end
30
+ end
31
+ end
metadata ADDED
@@ -0,0 +1,53 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: kajian-kajian_muslim
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Adrian Setyadi
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2017-12-15 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description:
14
+ email: adrian@setyadi.pro
15
+ executables: []
16
+ extensions: []
17
+ extra_rdoc_files: []
18
+ files:
19
+ - ".gitignore"
20
+ - Gemfile
21
+ - LICENSE.txt
22
+ - README.md
23
+ - Rakefile
24
+ - bin/console
25
+ - bin/setup
26
+ - kajian-kajian_muslim.gemspec
27
+ - lib/kajian/adapter/kajian_muslim.json
28
+ - lib/kajian/adapter/kajian_muslim.rb
29
+ homepage: https://github.com/styd/kajian-kajian_muslim
30
+ licenses:
31
+ - MIT
32
+ metadata: {}
33
+ post_install_message:
34
+ rdoc_options: []
35
+ require_paths:
36
+ - lib
37
+ required_ruby_version: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - ">="
40
+ - !ruby/object:Gem::Version
41
+ version: '0'
42
+ required_rubygems_version: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - ">="
45
+ - !ruby/object:Gem::Version
46
+ version: '0'
47
+ requirements: []
48
+ rubyforge_project:
49
+ rubygems_version: 2.6.11
50
+ signing_key:
51
+ specification_version: 4
52
+ summary: Plugin/Adapter untuk pustaka Kajian.
53
+ test_files: []