sass-times 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +7 -0
  2. data/lib/sass-times.rb +15 -0
  3. metadata +58 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 4bfc268d59e4e50dda423df415d6fa8141972c16
4
+ data.tar.gz: 5e17d12ef1533245edd1a9382e41fa94866e9e98
5
+ SHA512:
6
+ metadata.gz: afddad1533bca6981be8e5e4d11790d92f18ba14351814b47e23046bc6c7b9ff804f64abdfe084cddd5937542492c9272c80bca98275135f3db4c8f9a88a5330
7
+ data.tar.gz: 06c5b02da1810c7cd602931ac7aa8728a32323ebda2a2281d5c25ad76b198d26b7e09c9b157a1235b777de2a38b2a888301045ecfd97a53ae0bc489a716350ef
data/lib/sass-times.rb ADDED
@@ -0,0 +1,15 @@
1
+ unless defined?(Sass)
2
+ require 'sass'
3
+ end
4
+
5
+ module Sass::Script::Functions
6
+ def timestamp()
7
+ return Sass::Script::String.new(Time.now.to_s)
8
+ end
9
+ def strftime(format){
10
+ return Sass::Script::Value::String.new(Time.now.strftime(format.value))
11
+ }
12
+ def unix_timestamp()
13
+ return Sass::Script::String.new(Time.now.to_i.to_s)
14
+ end
15
+ end
metadata ADDED
@@ -0,0 +1,58 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: sass-times
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Rambo
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2016-07-19 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: sass
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '3.2'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '3.2'
27
+ description: Sass添加时间戳方法
28
+ email: alisa@kzcn.cc
29
+ executables: []
30
+ extensions: []
31
+ extra_rdoc_files: []
32
+ files:
33
+ - lib/sass-times.rb
34
+ homepage: https://github.com/Rambo/sass-times
35
+ licenses:
36
+ - MIT
37
+ metadata: {}
38
+ post_install_message:
39
+ rdoc_options: []
40
+ require_paths:
41
+ - lib
42
+ required_ruby_version: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - ">="
45
+ - !ruby/object:Gem::Version
46
+ version: '0'
47
+ required_rubygems_version: !ruby/object:Gem::Requirement
48
+ requirements:
49
+ - - ">="
50
+ - !ruby/object:Gem::Version
51
+ version: '0'
52
+ requirements: []
53
+ rubyforge_project:
54
+ rubygems_version: 2.5.1
55
+ signing_key:
56
+ specification_version: 4
57
+ summary: SASS 时间戳函数
58
+ test_files: []