Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
django-pipeline
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
django-pipeline
Commits
602d7c2d
Commit
602d7c2d
authored
Mar 30, 2013
by
Arnar Yngvason
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added LiveScriptCompiler
parent
893f3b65
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
0 deletions
+24
-0
pipeline/compilers/livescript.py
+21
-0
pipeline/conf/settings.py
+3
-0
No files found.
pipeline/compilers/livescript.py
0 → 100644
View file @
602d7c2d
from
__future__
import
unicode_literals
from
pipeline.conf
import
settings
from
pipeline.compilers
import
SubProcessCompiler
class
LiveScriptCompiler
(
SubProcessCompiler
):
output_extension
=
'js'
def
match_file
(
self
,
path
):
return
path
.
endswith
(
'.ls'
)
def
compile_file
(
self
,
infile
,
outfile
,
outdated
=
False
,
force
=
False
):
if
not
outdated
and
not
force
:
return
# File doesn't need to be recompiled
command
=
"
%
s -cp
%
s
%
s >
%
s"
%
(
settings
.
PIPELINE_LIVE_SCRIPT_BINARY
,
settings
.
PIPELINE_LIVE_SCRIPT_ARGUMENTS
,
infile
,
outfile
)
return
self
.
execute_command
(
command
)
pipeline/conf/settings.py
View file @
602d7c2d
...
@@ -48,6 +48,9 @@ PIPELINE_CSSMIN_ARGUMENTS = getattr(settings, 'PIPELINE_CSSMIN_ARGUMENTS', '')
...
@@ -48,6 +48,9 @@ PIPELINE_CSSMIN_ARGUMENTS = getattr(settings, 'PIPELINE_CSSMIN_ARGUMENTS', '')
PIPELINE_COFFEE_SCRIPT_BINARY
=
getattr
(
settings
,
'PIPELINE_COFFEE_SCRIPT_BINARY'
,
'/usr/bin/env coffee'
)
PIPELINE_COFFEE_SCRIPT_BINARY
=
getattr
(
settings
,
'PIPELINE_COFFEE_SCRIPT_BINARY'
,
'/usr/bin/env coffee'
)
PIPELINE_COFFEE_SCRIPT_ARGUMENTS
=
getattr
(
settings
,
'PIPELINE_COFFEE_SCRIPT_ARGUMENTS'
,
''
)
PIPELINE_COFFEE_SCRIPT_ARGUMENTS
=
getattr
(
settings
,
'PIPELINE_COFFEE_SCRIPT_ARGUMENTS'
,
''
)
PIPELINE_LIVE_SCRIPT_BINARY
=
getattr
(
settings
,
'PIPELINE_LIVE_SCRIPT_BINARY'
,
'/usr/bin/env lsc'
)
PIPELINE_LIVE_SCRIPT_ARGUMENTS
=
getattr
(
settings
,
'PIPELINE_LIVE_SCRIPT_ARGUMENTS'
,
''
)
PIPELINE_SASS_BINARY
=
getattr
(
settings
,
'PIPELINE_SASS_BINARY'
,
'/usr/bin/env sass'
)
PIPELINE_SASS_BINARY
=
getattr
(
settings
,
'PIPELINE_SASS_BINARY'
,
'/usr/bin/env sass'
)
PIPELINE_SASS_ARGUMENTS
=
getattr
(
settings
,
'PIPELINE_SASS_ARGUMENTS'
,
''
)
PIPELINE_SASS_ARGUMENTS
=
getattr
(
settings
,
'PIPELINE_SASS_ARGUMENTS'
,
''
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment