Skip to content

Instantly share code, notes, and snippets.

View import_fs.html
<link rel="import" href="elements/filesystem.html">
View tag_init.html
<polymer-filesystem></polymer-filesystem>
View filesystem.js
/*!
* Html5 LocalFileSystem polymer webcomponent
*
* © AOÛT 2010 - MAI 2014 | Stéphane Labbé
* Released under the MIT license
* https://github.com/asicfr/polymerFileSystem/blob/master/LICENSE.txt
*/
'use strict';
View WebComponent_template.html
<template>
<style>
/* styles for the custom element itself - lowest specificity */
:host { display: block; }
</style>
<template if="{{ systemOk === false }}">
<div class="alert alert-danger">
Your browser don't support FileSystem api. <a href="https://www.google.com/intl/fr_fr/chrome/browser/">Please, download chrome</a><br/>
View WebComponent_page_structure.html
<!--
* Html5 LocalFileSystem polymer webcomponent
*
* AOUT 2010 - MAI 2014 | Stephane Labbe
* Released under the MIT license
* https://github.com/asicfr/polymerFileSystem/blob/master/LICENSE.txt
-->
<!doctype html>
<html class="no-js">
View behavior.js
(function() {
// Start polymer
Polymer('polymer-filesystem', {
created: function() {
console.log("created");
// bind function 'callBackRefreshList' and 'callBackFsmChangeState' with 'this' current context
this.fsm = new fileSystemManager(this.callBackFsmChangeState.bind(this));
this.fsm.setCallBackAfterLoad(this.callBackRefreshList.bind(this));
console.log("fin created");
View Web_component_final_page.html
<!--
* Html5 LocalFileSystem polymer webcomponent
*
* AOUT 2010 - MAI 2014 | Stephane Labbe
* Released under the MIT license
* https://github.com/asicfr/polymerFileSystem/blob/master/LICENSE.txt
-->
<!doctype html>
<html class="no-js">
View gist:2c7b99947083d13a9c6b
REM --------------------------------------------------------------------------------------
REM Batch script to deploy MongoDB shard cluster.
REM For more detail on MongoDB shard cluster, see : http://docs.mongodb.org/manual/tutorial/deploy-shard-cluster/
REM --------------------------------------------------------------------------------------
@echo off
echo Start
set mongo_home_path=C:\Program Files\MongoDB 2.6 Standard\bin
set root_path=D:\temp\mongodb
set data_path=%root_path%\data_sharded
View gist:207682eeca5a6ac836ea
configS1 = {
"_id" : "s1",
"members" : [
{
"_id" : 1,
"host" : "localhost:37017"
},
{
"_id" : 2,
"host" : "localhost:37018"
View gist:9e70a374480dd5d85519
configS2 = {
"_id" : "s2",
"members" : [
{
"_id" : 1,
"host" : "localhost:47017"
},
{
"_id" : 2,
"host" : "localhost:47018"
You can’t perform that action at this time.