I want to add a additional parent level folder to CKFinder object.
Current setup:
On Create: /resource/events/0/
On Edit: /resource/events/{id}/
Wish On Edit:
{'/resource/events/{id}/', '/resource/events/0/', '/resource/shared/'}
The multiple folders solution will help in reducing the need to upload the same file on many events.
An ASP solution talks about adding the "ResourceTypes(3)" definition to add more sub-folders, but I am unable to find documentation on JavaScript API solution.
Unresolved Q&A:
http://ckeditor.com/forums/Support/Multiple-Images-folders
Related
I am trying to integrate Sonarqube analysis into the JavaScript sources of my project. It is a project using Spring components for the back-end, and as a first step, we did the integration of Java sources, without problem at that point.
We are using Sonarqube v5.6.3
The problem I am finding comes with the sonar.exclusions property. Apparently, that property can't exclude a folder that has already been added as sources (see question and answer explaining that exact issue).
I have the following lines in my pom.xml, which are not working properly; and that's understandable according to the aforelinked question:
<sonar.sources>src/main/java,src/main/docker,js-sources</sonar.sources>
<sonar.tests>src/test</sonar.tests>
<sonar.exclusions>**/target/*</sonar.exclusions>
The problem is: the front-end is made of several modules which are compiled one by one under their own /target sub-folder before being deployed all together into src/main/webapp. (They work as regular target folders: when a new compilation is launched, those folders get deleted/recreated.)
Those js-sources/moduleA/target, js-sources/moduleB/target, js-sources/moduleC/target folders are being automatically included as sources, and thus ignored by the exclusions directive. Those target folder still contain a /src subfolder, which makes it hard to use the limited Sonar patterns (full xpath-like selectors are not allowed) to include or exclude only certain paths.
As I don't think that the Sonarqube team was expecting everyone to add each little subfolder one by one (that's why they made patterns in the first term), I am looking for help: How do I exclude those per-module target folders living down the folder-tree inside my sources?
Another possibility would be that it is kind of a bug forcing us to store this config at a Jenkinsfile or even directly in the Jenkins config (at a job level), but I remain unsure and still think that something can be fixed in the way I am declaring the sources and exclusions.
Try
<sonar.exclusions>**/target/**/*</sonar.exclusions>
EDIT : while inclusions are useful in other cases, the accepted answer above is the correct one. I'm leaving mine, which follows, for the record and just as an example of using inclusions.
Try using inclusions rather than exclusions, I've setup a project as close to yours as I could guess from your description and I was able to ignore the target folders of the js-sources modules :
<properties>
<sonar.sources>src/main/java,js-sources</sonar.sources>
<sonar.inclusions>**/*.java, **/src/**/*.js</sonar.inclusions>
</properties>
You can read this as : 'scan all java files no matter where they are, scan only the javascript files that are found within the src of a subfolder of root'
I have a very large project with numerous bower dependencies. In many cases it is unclear whether these dependencies are even still in use within the application or if the version specified was chosen for a reason. Ideally, I would like to be able to put a comment for each dependency to state for which part of the application it is required, so as functionality in the application is removed, we can also remove unnecessary packages from the bower_components. Something like:
// videojs plug-in for adding navigable waveforms; used by the video component
"videojs-wavesurfer": "^1.2.2"
Unfortunately, json doesn't support commenting, but are there any possible solutions for annotating or better organizing a bower.json file to make it more understandable?
You cannot put comments in a JSON file. JSON is for data and nothing else.
If you would like to document your dependencies, consider adding a section to your README file that contains all of the information relevant to dependencies.
The classic approach to commenting JSON files is to add fake entries, which hopefully will be ignored by the consumer, such as:
"video-wavesurfer-comment":
"videojs plug-in for adding navigable waveforms; used by the video component"
For longer comments, use arrays:
"video-wavesurfer-comment": [
"videojs plug-in for adding navigable waveforms; used by the video component",
"Remove this for the non-video version."
]
Of course, you'll have to put these somewhere where someone won't try to parse them. For instance, they could not go WITHIN "dependencies":.
Where do I put .js files in Max?
I am currently using help from this thread on the Cycling forum to link Philips Hue lighting with Max 7.
https://cycling74.com/forums/topic/controlling-philips-hue-using-jython-and-phue/ and currently trying to use this method. https://gist.github.com/tgck/11185861#file-huerequestbuilder-js
I have got the patch in my patcher window but I don't know where to put the .js (HueRequestBuidler.js) file that it needs to run. Where do I put this file for Max to be able to read it and link with the patch?
I'm sure this has been asked before but I searched and couldn't find any answers that helped me out.
You typically place js files in the same folder as your patch. There should be a [js HueRequestBuidler] object in the patch that uses it.
Add the folder containing your .js files to the Max search path in Options/File Preferences. You can find more documentation here.
For the most part, I use the default TinyMCE plugins.
Every now and then, I make my own for my own specific needs.
To do so, I go to the tinymce directory, then the plugin directory, and then one of the individual plugin directories, and modify the script as necessary.
All is good except my memory (not my computer's but my head's). 4 months goes by, and I decide to upgrade to a newer version or something. Which ones did I change? I have no idea!
I would like to create my own directory called myTinyMCE_Plugins, and not even include it in the tinymce directory. That way I just need to remember to move my specific plugins over.
But when configuring TinyMCE, I can add the plugin name, but don't seem to be able to specify the plugin's path. Yes, I can use symbolic links, but this too is not ideal.
How can I locate TinyMCE plugins in a separate directory?
tinymce.init({
plugins: ["someDefaultPlugin someCustomPlugin"],
toolbar: "someDefaultPlugin | someCustomPlugin"
});
After asking the question, I found http://www.tinymce.com/wiki.php/Tutorials:Creating_a_plugin.
You can also have the plugin in any location you want by loading the plugin.js/plugin.min.js files directrly after the tinymce.js/tinymce.min.js.
Example of loading the plugin from another url
<script src="/tinymce/js/tinymce.min.js"></script>
<script src="/scripts/my.tinymce.plugin.js"></script>
<script>
tinymce.init({..});
</script>
I want to make a web based application that can have plugins/apps 'installed' to it. What i mean by Apps is say a weather app which has its own CSS and JS files in a container with a specific ID like id="Weather-app".
The Problems: (Assuming everything is on the same server)
Having Duplicate IDs, Class'
Conflicting script and style sheets
how to actually check a folder named 'Plugins', Find a file named Weather-app and then load the contents of 'Weather-app' into the main Application.
I have looked around on Google and haven't managed to find any information on how you would go about this. Hopefully someone on here will know. I would like to use JavaScript & JQuery if possible. I dont know if there is already a source out there for this purpose but if there is a link would be great!
1 - Avoid the use of IDs for generics, always use classes instead.
2 - Prefix the classes on HTML generated by plugins you are creating with some name space. i.e.: js-plugin-foobar-nameOfClass
You can avoid having the user add a ".js" and a ".css" file for each pluggin. You can generate css classes with javascript. That way you will only have to import one file for each pluggin: How to dynamically create CSS class in JavaScript and apply?
Take a look at the jQuery widget factory, you can build your plugins to use it, and that should facilitate your life. They also have some coding guidelines: http://jqueryui.com/widget/