linkedin2cv 0.0.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 +7 -0
- data/.buildpacks +2 -0
- data/.bundle/config +1 -0
- data/.gitignore +7 -0
- data/.node +1 -0
- data/.travis.yml +21 -0
- data/Gemfile +5 -0
- data/Gemfile.lock +119 -0
- data/Procfile +3 -0
- data/README.md +32 -0
- data/Rakefile +6 -0
- data/Vagrantfile +16 -0
- data/app/routes/api.rb +101 -0
- data/app/routes/web.rb +132 -0
- data/app/views/hello.erb +36 -0
- data/app/views/home.erb +12 -0
- data/app/views/index.haml +11 -0
- data/app.rb +26 -0
- data/config.ru +6 -0
- data/config.yml +31 -0
- data/lib/linkedin2cv/cli/command.rb +46 -0
- data/lib/linkedin2cv/converter.rb +116 -0
- data/lib/linkedin2cv/logging.rb +35 -0
- data/lib/linkedin2cv/renderer/latex_renderer.rb +64 -0
- data/lib/linkedin2cv/version.rb +3 -0
- data/linkedin2cv.gemspec +49 -0
- data/public/.bowerrc +3 -0
- data/public/.editorconfig +21 -0
- data/public/.gitattributes +1 -0
- data/public/.gitignore +5 -0
- data/public/.jshintrc +24 -0
- data/public/.travis.yml +7 -0
- data/public/Gruntfile.js +487 -0
- data/public/app/.buildignore +1 -0
- data/public/app/.htaccess +543 -0
- data/public/app/404.html +157 -0
- data/public/app/favicon.ico +0 -0
- data/public/app/images/yeoman.png +0 -0
- data/public/app/index.html +73 -0
- data/public/app/robots.txt +3 -0
- data/public/app/scripts/app.js +20 -0
- data/public/app/scripts/controllers/main.js +21 -0
- data/public/app/scripts/services/linkedin2cv.js +93 -0
- data/public/app/styles/main.scss +95 -0
- data/public/app/views/main.html +23 -0
- data/public/bower.json +19 -0
- data/public/karma-e2e.conf.js +54 -0
- data/public/karma.conf.js +56 -0
- data/public/package.json +41 -0
- data/public/test/.jshintrc +36 -0
- data/public/test/runner.html +10 -0
- data/public/test/spec/controllers/main.js +22 -0
- data/public/test/spec/services/happyapi.js +18 -0
- data/public/test/spec/services/happyservice.js +18 -0
- data/spec/converter_spec.rb +83 -0
- data/spec/mocks/config.yml +31 -0
- data/spec/mocks/profile.json +866 -0
- data/spec/spec_helper.rb +13 -0
- data/templates/cv.erb +327 -0
- data/templates/foo.asciidoc +11 -0
- data/templates/foo.latex +230 -0
- data/test.rb +109 -0
- data/test.sh +6 -0
- data/teust.rb +75 -0
- metadata +434 -0
@@ -0,0 +1,83 @@
|
|
1
|
+
require 'rspec'
|
2
|
+
require 'linkedin2cv/cli/command'
|
3
|
+
require 'linkedin2cv/converter'
|
4
|
+
require 'spec_helper'
|
5
|
+
require 'linkedin-oauth2'
|
6
|
+
|
7
|
+
describe Linkedin2CV::Converter do
|
8
|
+
|
9
|
+
before do
|
10
|
+
@client = Linkedin2CV::Converter.new
|
11
|
+
@profile = @client.get_profile
|
12
|
+
@config = YAML.load_file(__dir__ + "/mocks/config.yml")
|
13
|
+
|
14
|
+
end
|
15
|
+
|
16
|
+
it 'Should Fetch skills' do
|
17
|
+
# puts @profile.member_url_resources
|
18
|
+
# @profile.skills.all.map do |skill|
|
19
|
+
# puts skill.skill.name
|
20
|
+
# end
|
21
|
+
|
22
|
+
# Should get back a Mash of objects
|
23
|
+
expect(@profile.skills).to be_an_instance_of(LinkedIn::Mash)
|
24
|
+
end
|
25
|
+
|
26
|
+
it 'Should Fetch education' do
|
27
|
+
expect(@profile.educations).to be_an_instance_of(LinkedIn::Mash)
|
28
|
+
end
|
29
|
+
|
30
|
+
it 'Should Fetch associations' do
|
31
|
+
expect(@profile.associations).to be_an_instance_of(String)
|
32
|
+
end
|
33
|
+
|
34
|
+
it 'Should Fetch interests' do
|
35
|
+
expect(@profile.interests).to be_an_instance_of(String)
|
36
|
+
end
|
37
|
+
|
38
|
+
it 'Should Fetch recommendations' do
|
39
|
+
expect(@profile.recommendations_received).to be_an_instance_of(LinkedIn::Mash)
|
40
|
+
end
|
41
|
+
|
42
|
+
it 'Should Fetch jobs' do
|
43
|
+
expect(@profile.job_bookmarks).to be_an_instance_of(LinkedIn::Mash)
|
44
|
+
end
|
45
|
+
|
46
|
+
it 'Should Fetch current jobs' do
|
47
|
+
expect(@profile.three_current_positions).to be_an_instance_of(LinkedIn::Mash)
|
48
|
+
end
|
49
|
+
|
50
|
+
it 'Should Fetch past jobs' do
|
51
|
+
expect(@profile.three_past_positions).to be_an_instance_of(LinkedIn::Mash)
|
52
|
+
end
|
53
|
+
|
54
|
+
it 'Should Fetch URLs' do
|
55
|
+
expect(@profile.member_url_resources).to be_an_instance_of(LinkedIn::Mash)
|
56
|
+
end
|
57
|
+
|
58
|
+
it 'Should compile latex on the CLI' do
|
59
|
+
|
60
|
+
end
|
61
|
+
|
62
|
+
|
63
|
+
it 'Should create a latex Resume' do
|
64
|
+
@client.create_resume(@config)
|
65
|
+
|
66
|
+
# @config['skills']['extra'].each do |k|
|
67
|
+
# # puts k
|
68
|
+
# k.keys.each do |category|
|
69
|
+
# k[category].each do |v|
|
70
|
+
# puts v
|
71
|
+
# end
|
72
|
+
# end
|
73
|
+
# end
|
74
|
+
|
75
|
+
end
|
76
|
+
|
77
|
+
it 'Should monkey patch the ERB Compiler to escape LaTeX special chars' do
|
78
|
+
# puts ERB.new('<%=@profile.location.name %>')
|
79
|
+
replaced = ERB.new("<%= 'this & interesting' %><%= 'I have lots of $$ which is >= Bill Gates but < some Middle Eastern oil tychoons ~ net % of the detail' %>").result
|
80
|
+
expect(replaced).to eql('this \& interestingI have lots of \$\$ which is \textgreater= Bill Gates but \textless some Middle Eastern oil tychoons \textasciitilde net \% of the detail')
|
81
|
+
end
|
82
|
+
|
83
|
+
end
|
@@ -0,0 +1,31 @@
|
|
1
|
+
home_phone: +61 3 1234 5678
|
2
|
+
mobile_phone: +61 422 123 456
|
3
|
+
|
4
|
+
references:
|
5
|
+
- bill:
|
6
|
+
projects: ["Melbourne IT AWS Migration \\ \"DevOps\""]
|
7
|
+
roles: ["Manager, Digital"]
|
8
|
+
first_name: Bill
|
9
|
+
last_name: Murry
|
10
|
+
phone: +61 3 0987 6543
|
11
|
+
email: bill@foobar.com
|
12
|
+
|
13
|
+
skills:
|
14
|
+
max: 10
|
15
|
+
extra:
|
16
|
+
- technical: [Solution Design & Architecture, REST, APIs, AWS, Puppet, Automation]
|
17
|
+
- languages: [Java, PHP, Ruby, Scala]
|
18
|
+
|
19
|
+
other:
|
20
|
+
interests: [The Internet, Human Computer Interaction & Usability, Basketball, Waterskiing\Wakeboarding, Snowboarding]
|
21
|
+
|
22
|
+
projects:
|
23
|
+
- "Melbourne IT AWS Migration \\ \"DevOps\"": "Melbourne IT"
|
24
|
+
- "Melbourne IT Website Refresh (In Progress)": "Melbourne IT"
|
25
|
+
- "Startup - Mobile App (Advertising)": "Freelance"
|
26
|
+
- "Transformation": "Melbourne IT"
|
27
|
+
- "Renewal - Conversion Rate Optimisation": "Melbourne IT"
|
28
|
+
- "Skylock - Cloud-based GPS Security Portal": "Freelance"
|
29
|
+
- "Substantiate - GPS logbook solutions": "Freelance"
|
30
|
+
- "Auto-renewal": "Melbourne IT"
|
31
|
+
- "Business Transformation Programme (IWS)": "Melbourne IT"
|