Merge pull request #1 from bgarret/gem

Gemify the plugin
3.0
David Bourguignon 2012-01-30 00:15:29 -08:00
commit 57fa761418
7 changed files with 30 additions and 4 deletions

1
.gitignore vendored 100644
View File

@ -0,0 +1 @@
*.gem

View File

@ -9,7 +9,11 @@ It's a Ruby on Rails port of the connexion kits published by the bank.
## INSTALL ## INSTALL
script/plugin install git://github.com/novelys/paiementcic.git script/plugin install git://github.com/novelys/paiementcic.git
or, in your Gemfile
gem 'paiement_cic', :git => 'git://github.com/novelys/paiementcic.git', :branch => 'gem'
## USAGE ## USAGE
@ -32,7 +36,7 @@ script/plugin install git://github.com/novelys/paiementcic.git
### in order controller : ### in order controller :
helper :paiement_cic helper :'paiement_cic/form'
### in the payment by card view : ### in the payment by card view :

View File

@ -1,2 +1,2 @@
require "paiement_cic" require "paiement_cic"
require "paiement_cic_helper" require "paiement_cic/form_helper"

View File

@ -14,6 +14,8 @@ class String
end end
class PaiementCic class PaiementCic
autoload :FormHelper, "paiement_cic/form_helper"
@@version = "3.0" # clé extraite grâce à extract2HmacSha1.html fourni par le Crédit Mutuel @@version = "3.0" # clé extraite grâce à extract2HmacSha1.html fourni par le Crédit Mutuel
cattr_accessor :version cattr_accessor :version

View File

@ -1,5 +1,5 @@
## refactor this ## refactor this
module PaiementCicHelper module PaiementCic::FormHelper
def paiement_cic_hidden_fields(order, price, order_transaction, options = {}) def paiement_cic_hidden_fields(order, price, order_transaction, options = {})
oa = PaiementCic.config(price, order_transaction.reference) oa = PaiementCic.config(price, order_transaction.reference)

View File

@ -0,0 +1,3 @@
class PaiementCic
VERSION = "0.1"
end

View File

@ -0,0 +1,16 @@
# encoding: utf-8
$:.push File.expand_path("../lib", __FILE__)
require "paiement_cic/version"
Gem::Specification.new do |s|
s.name = "paiement_cic"
s.version = PaiementCic::VERSION
s.platform = Gem::Platform::RUBY
s.authors = ["Novelys Team"]
s.homepage = "https://github.com/novelys/paiementcic"
s.summary = %q{CIC / Crédit Mutuel credit card payment toolbox}
s.description = %q{Paiement CIC is a gem to ease credit card payment with the CIC / Crédit Mutuel banks system. It's a Ruby on Rails port of the connexion kits published by the bank.}
s.files = `git ls-files`.split("\n")
s.require_paths = ["lib"]
end