Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
beat.editor
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
11
Issues
11
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
beat
beat.editor
Commits
3457169f
Commit
3457169f
authored
Oct 09, 2019
by
Samuel GAIST
Committed by
Samuel GAIST
Nov 15, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[buildout] Remove JS related scripts
parent
52a19134
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
41 deletions
+1
-41
buildout.cfg
buildout.cfg
+1
-7
conda/linkeditor.py
conda/linkeditor.py
+0
-34
No files found.
buildout.cfg
View file @
3457169f
[buildout]
parts = scripts
templates
parts = scripts
eggs = beat.editor
develop = .
newest = false
[scripts]
recipe = bob.buildout:scripts
[templates]
recipe = collective.recipe.cmd
cmds = ./bin/python conda/linkeditor.py
on_install = true
on_update = true
conda/linkeditor.py
deleted
100644 → 0
View file @
52a19134
#!/usr/bin/env python
# -*- coding: utf-8 -*-
'''Ensures the editor JS code is available during tests'''
import
os
import
sys
import
glob
key
=
'%%jsfiles%%'
scriptdir
=
os
.
path
.
realpath
(
os
.
path
.
dirname
(
sys
.
argv
[
0
]))
try
:
import
pkg_resources
import
beat.editorx
jsfiles
=
pkg_resources
.
resource_filename
(
beat
.
editor
.
__name__
,
'js'
)
print
(
'Running test (beat.editor import suceeded) - setting javascript path to %s'
%
jsfiles
)
except
ImportError
as
e
:
jsfiles
=
os
.
path
.
realpath
(
os
.
path
.
join
(
scriptdir
,
'..'
,
'beat'
,
'editor'
,
'js'
))
print
(
'Running build (beat.editor import failed) - setting javascript path to %s'
%
jsfiles
)
if
not
os
.
path
.
exists
(
jsfiles
):
print
(
' Creating directory %s'
%
jsfiles
)
os
.
makedirs
(
jsfiles
)
templatedir
=
os
.
path
.
realpath
(
os
.
path
.
join
(
scriptdir
,
'js'
))
for
k
in
glob
.
glob
(
os
.
path
.
join
(
templatedir
,
'*.template'
)):
output
=
os
.
path
.
splitext
(
k
)[
0
]
print
(
' ** Replacing template %s -> %s'
%
(
k
,
output
))
with
open
(
k
,
'rt'
)
as
reader
,
open
(
output
,
'wt'
)
as
writer
:
for
line
in
reader
:
if
key
in
line
:
line
=
line
.
replace
(
key
,
jsfiles
)
writer
.
writelines
([
line
])
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