contracter 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: ee7ca5e3dd4c8fbc12a97e53308bb106f0a48e47
4
+ data.tar.gz: 0d5b58aed111486e9242cb383b413d5442c08c10
5
+ SHA512:
6
+ metadata.gz: 111fc80dbc288039c2af3a26db2a081fbe2ca066f02f986411fc744c4778ce38e020eae043a0ee4f540e226b9616ea9665b6881fa063299c5fb544a7754236bd
7
+ data.tar.gz: f93ffec17804a33ca882e66d64e8b4a18bfde151230c07599f55c4e9d8fdfcf71ca1345af8169b01d1af1ecaac871a81fea52a7ae924040bf26a5a2d7b5e23d2
data/.gitignore ADDED
@@ -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/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --format documentation
2
+ --color
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in contracter.gemspec
4
+ gemspec
data/README.md ADDED
@@ -0,0 +1,36 @@
1
+ # Contracter
2
+
3
+ Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/contracter`. To experiment with that code, run `bin/console` for an interactive prompt.
4
+
5
+ TODO: Delete this and the text above, and describe your gem
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's Gemfile:
10
+
11
+ ```ruby
12
+ gem 'contracter'
13
+ ```
14
+
15
+ And then execute:
16
+
17
+ $ bundle
18
+
19
+ Or install it yourself as:
20
+
21
+ $ gem install contracter
22
+
23
+ ## Usage
24
+
25
+ TODO: Write usage instructions here
26
+
27
+ ## Development
28
+
29
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
30
+
31
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
32
+
33
+ ## Contributing
34
+
35
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/contracter.
36
+
data/Rakefile ADDED
@@ -0,0 +1,6 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+
6
+ task :default => :spec
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "contracter"
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
data/bin/setup ADDED
@@ -0,0 +1,7 @@
1
+ #!/bin/bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+
5
+ bundle install
6
+
7
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,24 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'contracter/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "contracter"
8
+ spec.version = Contracter::VERSION
9
+ spec.authors = ["Remi Gelinas"]
10
+ spec.email = ["remigelinas1@gmail.com"]
11
+
12
+ spec.summary = %q{A web development contract generator.}
13
+ spec.description = %q{A Ruby gem that provides a simple DSL for generating web development contracts.}
14
+ spec.homepage = "https://github.com/remi-gelinas/contracter"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
17
+ spec.bindir = "exe"
18
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_development_dependency "bundler", "~> 1.10"
22
+ spec.add_development_dependency "rake", "~> 10.0"
23
+ spec.add_development_dependency "rspec"
24
+ end
@@ -0,0 +1,37 @@
1
+ class Contract
2
+ def company c
3
+ @company = c
4
+ end
5
+
6
+ def client c
7
+ @client = c
8
+ end
9
+
10
+ def client_address a
11
+ @client_address = a
12
+ end
13
+
14
+ def service s
15
+ @service = s
16
+ end
17
+
18
+ def estimated_total t
19
+ @estimated_total = t
20
+ end
21
+
22
+ def payment_details d
23
+ @payment_details = d
24
+ end
25
+
26
+ def payment_schedule s
27
+ @payment_schedule = s
28
+ end
29
+
30
+ def date d
31
+ @date = d
32
+ end
33
+
34
+ def template_path p
35
+ @template_path = p
36
+ end
37
+ end
@@ -0,0 +1,111 @@
1
+
2
+
3
+ Between me ([company])
4
+ and you ([client])
5
+
6
+ ## Summary:
7
+
8
+ I'll always do my best to fulfill your needs and meet your expectations, but it’s important to have things written down so that we both know what’s what, who should do what and when, and what will happen if something goes wrong. In this contract you won’t find any complicated legal terms or long passages of unreadable text. I’ve no desire to trick you into signing something that you might later regret. What I do want is what’s best for both parties, now and in the future.
9
+
10
+ So in short;
11
+
12
+ You ([client]), located at [client_address] are hiring me ([company]) located at [company_address] to [service] for the estimated total price of[estimated_total] as outlined in my previous correspondence. Of course it’s a little more complicated, but I'll get to that.
13
+
14
+ ## What do both parties agree to do?
15
+
16
+ *You:* You have the authority to enter into this contract on behalf of yourself, your company or your organization. You’ll give me the assets and information I tell you I need to complete the project. You’ll do this when I ask and provide it in the formats I need. You’ll review my work, and provide feedback and approval in a timely manner too. Deadlines work two ways, so you’ll also be bound by dates we set together. You also agree to stick to the payment schedule set out at the end of this contract.
17
+
18
+ *Me:* I have the experience and ability to do everything I’ve agreed with you and I'll do it all in a professional and timely manner. I'll endeavor to meet every deadline that’s set and on top of that I'll maintain the confidentiality of everything you give me.
19
+
20
+ ## Getting down to the nitty gritty
21
+
22
+ ### Design
23
+
24
+ I create look-and-feel designs, and flexible layouts that can adapt to the capabilities of many devices and screen sizes. I create designs iteratively and use predominantly HTML and CSS so I won’t waste time mocking up every template as a static visual. I may use visuals to indicate a creative direction (colour, texture and typography.) I call that ‘atmosphere.’
25
+
26
+ You’ll have plenty of opportunities to review my work and provide feedback. I'll either share a Dropbox folder or Github repository with you and I'll endeavor to maintain regular contact. If, at any stage, you’re not happy with the direction my work is taking, you’ll pay me in full for everything I’ve produced until that point and cancel this contract.
27
+
28
+ ### Text content
29
+
30
+ Unless agreed separately, I’m not responsible for inputting text or images into your content management system. If you’d like me to create new content or input for you, I can provide a separate estimate for that.
31
+
32
+ ### Graphics and photographs
33
+
34
+ You should supply graphic files in an editable, vector digital format. You should supply photographs in a high resolution digital format.
35
+
36
+ ### Architecture
37
+
38
+ I deliver web pages using HTML markup and CSS stylesheets for styling, and Javascript for communication with the back-end. I deliver web applications using a predominantly Ruby on Rails back-end connected to a PostgreSQL database, with a predominantly React.js front-end.
39
+
40
+ ### Browser testing
41
+
42
+ Browser testing no longer means attempting to make a website look the same in browsers of different capabilities or on devices with different size screens. It does mean ensuring that a person’s experience of a design should be appropriate to the capabilities of a browser or device.
43
+
44
+ ### Desktop browser testing
45
+
46
+ I test my work in current versions of major desktop browsers including those made by Apple (Safari), Google (Chrome), Microsoft (Edge), Mozilla Firefox and Opera. I'll also test to ensure that people who use Microsoft Internet Explorer 11 for Windows get an appropriate experience. I won’t test in other older browsers unless I agreed separately. If you need an enhanced design for an older browser, I can provide a separate estimate for that.
47
+
48
+ ### Mobile browser testing
49
+
50
+ Testing using popular smaller screen devices is essential in ensuring that a person’s experience of a design is appropriate to the capabilities of the device they’re using. I test my designs in:
51
+
52
+ Google Chrome
53
+ Android: Google Chrome on Android Emulator
54
+
55
+ I won’t test in Blackberry, Opera Mini/Mobile, specific Android devices, Windows or other mobile browsers unless agreed separately.
56
+
57
+ ### Technical support
58
+
59
+ I’m not a website hosting company so I don’t offer support for website hosting, email or other services relating to hosting. You may already have professional hosting and you might even manage that hosting in-home; if you do, great. If you don’t, I can set up an account for you at one of my preferred hosting providers. I can set up your site on a server, plus any statistics software such as Google Analytics, and I can provide a separate estimate for that. Then, the updates to, and management of that server will be up to you, unless we agree
60
+ separately.
61
+
62
+ ### Search engine optimization (SEO)
63
+
64
+ I don’t guarantee improvements to your website's search engine ranking, but the web pages that I develop are accessible to search engines.
65
+
66
+ ### Changes and revisions
67
+
68
+ I know from experience that fixed-price contracts are rarely beneficial to you, as they often limit you to your earliest ideas. I don’t want to limit your ability to change your mind. The price at the beginning of this contract is based on the
69
+ number of weeks that I estimate I'll need to accomplish everything you’ve told me you want to achieve, but I’m happy to be flexible. If you want to change your mind or add anything new, that won’t be a problem as I'll provide a separate estimate for those additional weeks.
70
+
71
+ ### Legal stuff
72
+
73
+ I can’t guarantee that my work will be error-free and so I can’t be liable to you or any third-party for damages, including lost profits, lost savings or other incidental, consequential or special damages, even if you’ve advised me of them. Finally, if any provision of this contract shall be unlawful, void, or for any reason unenforceable, then that provision shall be deemed severable from this contract and shall not affect the validity and enforceability of any remaining provisions.
74
+
75
+ ### Copyrights
76
+
77
+ First, you guarantee that all elements of text, images or other artwork you provide are either owned by your good selves, or that you’ve permission to use them.
78
+
79
+ Then, when your final payment has cleared, copyright will be automatically assigned as follows:
80
+
81
+ You’ll own the visual elements that I create for this project. I'll give you source files and finished files and you should keep them somewhere safe as I’re not required to keep a copy. You own all elements of text, images and data you provided, unless someone else owns them.
82
+
83
+ I'll own the unique combination of these elements that constitutes a complete design and I'll license its use to you, exclusively and in perpetuity for this project only, unless I agree otherwise.
84
+
85
+ ### Displaying my work
86
+
87
+ I love to show off my work, so I reserve the right to display all aspects of my creative work, including sketches, work-in-progress designs and the completed project on my portfolio and in articles on websites, in magazine articles and in books.
88
+
89
+ ### Payment schedule
90
+
91
+ I’m sure you understand how important it is as a small business that you pay the invoices that I send you promptly. As I’m also sure you’ll want to stay friends, you agree to stick tight to the following payment schedule.
92
+
93
+ [payment_details]
94
+ [payment_schedule]
95
+
96
+
97
+ I issue invoices electronically. my payment terms are [grace_period] days from the date of invoice by Interact eTransfer. All proposals are quoted in [currency] and payments will be made at the equivalent conversion rate at the date the transfer is made.
98
+
99
+ You agree to pay all charges associated with international transfers of funds. The appropriate transfer details will be printed on my electronic invoice. I reserve the right to charge interest on all overdue debts at the rate of [interest_percentage] per month or part of a month.
100
+
101
+ ### But where’s all the horrible small print?
102
+
103
+ Just like a parking ticket, you can’t transfer this contract to anyone else without my permission. This contract stays in place and need not be renewed. If for some reason one part of this contract becomes invalid or unenforceable, the remaining parts of it remain in place.
104
+
105
+ Although the language is simple, the intentions are serious and this contract is a legal document under exclusive jurisdiction of [English and Welsh] courts.
106
+
107
+ ### The dotted line
108
+
109
+ Signed by and on behalf of [company] _____________________
110
+ Signed by and on behalf of [client]_____________________
111
+ Date [date]
@@ -0,0 +1,3 @@
1
+ class Contracter
2
+ VERSION = "0.1.0"
3
+ end
data/lib/contracter.rb ADDED
@@ -0,0 +1,19 @@
1
+ require "contracter/contract"
2
+
3
+ class Contracter
4
+ def self.build &block
5
+ c = Contract.new
6
+ c.instance_eval(&block)
7
+
8
+ t = (c.instance_variable_get("@template_path") or File.expand_path("lib/contracter/template.md"))
9
+ self.fill_template(File.read(t), c)
10
+ end
11
+
12
+ private
13
+ def self.fill_template t, c
14
+ c.instance_variables.map(&:to_s).each do |v|
15
+ t.gsub!(/\[#{Regexp.quote(v.gsub("@", ""))}\]/, c.instance_variable_get(v))
16
+ end
17
+ t.gsub(/\[\w+?\]/, "MISSING")
18
+ end
19
+ end
metadata ADDED
@@ -0,0 +1,98 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: contracter
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Remi Gelinas
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2015-12-08 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.10'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.10'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ description: A Ruby gem that provides a simple DSL for generating web development
56
+ contracts.
57
+ email:
58
+ - remigelinas1@gmail.com
59
+ executables: []
60
+ extensions: []
61
+ extra_rdoc_files: []
62
+ files:
63
+ - ".gitignore"
64
+ - ".rspec"
65
+ - Gemfile
66
+ - README.md
67
+ - Rakefile
68
+ - bin/console
69
+ - bin/setup
70
+ - contracter.gemspec
71
+ - lib/contracter.rb
72
+ - lib/contracter/contract.rb
73
+ - lib/contracter/template.md
74
+ - lib/contracter/version.rb
75
+ homepage: https://github.com/remi-gelinas/contracter
76
+ licenses: []
77
+ metadata: {}
78
+ post_install_message:
79
+ rdoc_options: []
80
+ require_paths:
81
+ - lib
82
+ required_ruby_version: !ruby/object:Gem::Requirement
83
+ requirements:
84
+ - - ">="
85
+ - !ruby/object:Gem::Version
86
+ version: '0'
87
+ required_rubygems_version: !ruby/object:Gem::Requirement
88
+ requirements:
89
+ - - ">="
90
+ - !ruby/object:Gem::Version
91
+ version: '0'
92
+ requirements: []
93
+ rubyforge_project:
94
+ rubygems_version: 2.5.0
95
+ signing_key:
96
+ specification_version: 4
97
+ summary: A web development contract generator.
98
+ test_files: []