Package.describe({
  summary: "Encrypt account secrets stored in the database",
  version: '1.0.5'
});

Package.onUse(function (api) {
  api.use("npm-node-aes-gcm@=0.1.3_6");

  api.export("OAuthEncryption", ["server"]);
  api.use("underscore");
  api.addFiles("encrypt.js", ["server"]);
});

Package.onTest(function (api) {
  api.use("tinytest");
  api.use("oauth-encryption");
  api.addFiles("encrypt_tests.js", ["server"]);
});


keep keep keep keep replace replace replace replace keep

var _ = require('underscore');

var archinfo = require('./archinfo.js');
var buildmessage = require('./buildmessage.js');
var bundler = require('./bundler.js');
var isopack = require('./isopack.js');
var isopackets = require('./isopackets.js');
var linker = require('./linker.js');
var meteorNpm = require('./meteor-npm.js');
var watch = require('./watch.js');
var Console = require('./console.js').Console;
var files = require('./files.js');
var colonConverter = require('./colon-converter.js');
var linterPluginModule = require('./linter-plugin.js');

var compiler = exports;

// Whenever you change anything about the code that generates isopacks, bump
// this version number. The idea is that the "format" field of the isopack
// JSON file only changes when the actual specified structure of the
// isopack/unibuild changes, but this version (which is build-tool-specific)
// can change when the the contents (not structure) of the built output
// changes. So eg, if we improve the linker's static analysis, this should be
// bumped.
//
// You should also update this whenever you update any of the packages used
// directly by the isopack creation process (eg js-analyze) since they do not
// end up as watched dependencies. (At least for now, packages only used in
// target creation (eg minifiers) don't require you to update BUILT_BY, though
// you will need to quit and rerun "meteor run".)
compiler.BUILT_BY = 'meteor/16';

// This is a list of all possible architectures that a build can target. (Client
// is expanded into 'web.browser' and 'web.cordova')
compiler.ALL_ARCHES = [ "os", "web.browser", "web.cordova" ];

compiler.compile = function (packageSource, options) {
  buildmessage.assertInCapture();

  var packageMap = options.packageMap;
  var isopackCache = options.isopackCache;
  var includeCordovaUnibuild = options.includeCordovaUnibuild;

  var pluginWatchSet = packageSource.pluginWatchSet.clone();
  var plugins = {};

  var pluginProviderPackageNames = {};

  // Build plugins
  _.each(packageSource.pluginInfo, function (info) {
    buildmessage.enterJob({
      title: "building plugin `" + info.name +
        "` in package `" + packageSource.name + "`",
      rootPath: packageSource.sourceRoot
    }, function () {
      // XXX we should probably also pass options.noLineNumbers into
      //     buildJsImage so it can pass it back to its call to
      //     compiler.compile
      var buildResult = bundler.buildJsImage({
        name: info.name,
        packageMap: packageMap,
        isopackCache: isopackCache,
        use: info.use,
        sourceRoot: packageSource.sourceRoot,
        sources: info.sources,
        npmDependencies: info.npmDependencies,
        // Plugins have their own npm dependencies separate from the
        // rest of the package, so they need their own separate npm
        // shrinkwrap and cache state.
        npmDir: files.pathResolve(
          files.pathJoin(packageSource.sourceRoot, '.npm', 'plugin', info.name))
      });
      // Add this plugin's dependencies to our "plugin dependency"
      // WatchSet. buildResult.watchSet will end up being the merged
      // watchSets of all of the unibuilds of the plugin -- plugins have
      // only one unibuild and this should end up essentially being just
      // the source files of the plugin.
      //
      // Note that we do this even on error, so that you can fix the error
      // and have the runner restart.
      pluginWatchSet.merge(buildResult.watchSet);

      if (buildmessage.jobHasMessages())
        return;

      _.each(buildResult.usedPackageNames, function (packageName) {
        pluginProviderPackageNames[packageName] = true;
      });

      // Register the built plugin's code.
      if (!_.has(plugins, info.name))
        plugins[info.name] = {};
      plugins[info.name][buildResult.image.arch] = buildResult.image;
    });
  });

  // Grab any npm dependencies. Keep them in a cache in the package
  // source directory so we don't have to do this from scratch on
  // every build.
  //
  // Go through a specialized npm dependencies update process,
  // ensuring we don't get new versions of any (sub)dependencies. This
  // process also runs mostly safely multiple times in parallel (which
  // could happen if you have two apps running locally using the same
  // package).
  //
  // We run this even if we have no dependencies, because we might
  // need to delete dependencies we used to have.
  var isPortable = true;
  var nodeModulesPath = null;
  if (packageSource.npmCacheDirectory) {
    if (meteorNpm.updateDependencies(packageSource.name,
                                     packageSource.npmCacheDirectory,
                                     packageSource.npmDependencies)) {
      nodeModulesPath = files.pathJoin(packageSource.npmCacheDirectory,
                                  'node_modules');
      if (! meteorNpm.dependenciesArePortable(packageSource.npmCacheDirectory))
        isPortable = false;
    }
  }

  var isopk = new isopack.Isopack;
  isopk.initFromOptions({
    name: packageSource.name,
    metadata: packageSource.metadata,
    version: packageSource.version,
    isTest: packageSource.isTest,
    plugins: plugins,
    pluginWatchSet: pluginWatchSet,
    cordovaDependencies: packageSource.cordovaDependencies,
    npmDiscards: packageSource.npmDiscards,
    includeTool: packageSource.includeTool,
    debugOnly: packageSource.debugOnly
  });

  _.each(packageSource.architectures, function (unibuild) {
    if (unibuild.arch === 'web.cordova' && ! includeCordovaUnibuild)
      return;

    var unibuildResult = compileUnibuild({
      isopack: isopk,
      sourceArch: unibuild,
      isopackCache: isopackCache,
      nodeModulesPath: nodeModulesPath,
      isPortable: isPortable,
      noLineNumbers: options.noLineNumbers
    });
    _.extend(pluginProviderPackageNames,
             unibuildResult.pluginProviderPackageNames);
  });

  if (options.includePluginProviderPackageMap) {
    isopk.setPluginProviderPackageMap(
      packageMap.makeSubsetMap(_.keys(pluginProviderPackageNames)));
  }

  return isopk;
};

// options.sourceArch is a SourceArch to compile.  Process all source files
// through the appropriate handlers and run the prelink phase on any resulting
// JavaScript. Create a new Unibuild and add it to options.isopack.
//
// Returns a list of source files that were used in the compilation.
var compileUnibuild = function (options) {
  buildmessage.assertInCapture();

  var isopk = options.isopack;
  var inputSourceArch = options.sourceArch;
  var isopackCache = options.isopackCache;
  var nodeModulesPath = options.nodeModulesPath;
  var isPortable = options.isPortable;
  var noLineNumbers = options.noLineNumbers;

  var isApp = ! inputSourceArch.pkg.name;
  var resources = [];
  var js = [];
  var pluginProviderPackageNames = {};
  // The current package always is a plugin provider. (This also means we no
  // longer need a buildOfPath entry in buildinfo.json.)
  pluginProviderPackageNames[isopk.name] = true;
  var watchSet = inputSourceArch.watchSet.clone();

  // *** Determine and load active plugins

  // XXX we used to include our own extensions only if we were the
  // "use" role. now we include them everywhere because we don't have
  // a special "use" role anymore. it's not totally clear to me what
  // the correct behavior should be -- we need to resolve whether we
  // think about extensions as being global to a package or particular
  // to a unibuild.

  // (there's also some weirdness here with handling implies, because
  // the implies field is on the target unibuild, but we really only care
  // about packages.)
  var activePluginPackages = [isopk];

  // We don't use plugins from weak dependencies, because the ability
  // to compile a certain type of file shouldn't depend on whether or
  // not some unrelated package in the target has a dependency. And we
  // skip unordered dependencies, because it's not going to work to
  // have circular build-time dependencies.
  //
  // eachUsedUnibuild takes care of pulling in implied dependencies for us (eg,
  // templating from standard-app-packages).
  //
  // We pass archinfo.host here, not self.arch, because it may be more specific,
  // and because plugins always have to run on the host architecture.
  compiler.eachUsedUnibuild({
    dependencies: inputSourceArch.uses,
    arch: archinfo.host(),
    isopackCache: isopackCache,
    skipUnordered: true
    // implicitly skip weak deps by not specifying acceptableWeakPackages option
  }, function (unibuild) {
    if (unibuild.pkg.name === isopk.name)
      return;
    pluginProviderPackageNames[unibuild.pkg.name] = true;
    // If other package is built from source, then we need to rebuild this
    // package if any file in the other package that could define a plugin
    // changes.
    watchSet.merge(unibuild.pkg.pluginWatchSet);

    if (_.isEmpty(unibuild.pkg.plugins))
      return;
    activePluginPackages.push(unibuild.pkg);
  });

  activePluginPackages = _.uniq(activePluginPackages);

  // *** Assemble the list of source file handlers from the plugins
  // XXX BBP redoc
  var allHandlersWithPkgs = {};
  var compilerPluginsByExtension = {};
  var linterPluginsByExtension = {};
  var sourceExtensions = {};  // maps source extensions to isTemplate

  sourceExtensions['js'] = false;
  allHandlersWithPkgs['js'] = {
    pkgName: null /* native handler */,
    handler: function (compileStep) {
      // This is a hardcoded handler for *.js files. Since plugins
      // are written in JavaScript we have to start somewhere.

      var options = {
        data: compileStep.read().toString('utf8'),
        path: compileStep.inputPath,
        sourcePath: compileStep.inputPath,
        _hash: compileStep._hash
      };

      if (compileStep.fileOptions.hasOwnProperty("bare")) {
        options.bare = compileStep.fileOptions.bare;
      } else if (compileStep.fileOptions.hasOwnProperty("raw")) {
        // XXX eventually get rid of backward-compatibility "raw" name
        // XXX COMPAT WITH 0.6.4
        options.bare = compileStep.fileOptions.raw;
      }

      compileStep.addJavaScript(options);
    }
  };

  _.each(activePluginPackages, function (otherPkg) {
    otherPkg.ensurePluginsInitialized();

    // Iterate over the legacy source handlers.
    _.each(otherPkg.getSourceHandlers(), function (sourceHandler, ext) {
      // XXX comparing function text here seems wrong.
      if (_.has(allHandlersWithPkgs, ext) &&
          allHandlersWithPkgs[ext].handler.toString() !== sourceHandler.handler.toString()) {
        buildmessage.error(
          "conflict: two packages included in " +
            (inputSourceArch.pkg.name || "the app") + ", " +
            (allHandlersWithPkgs[ext].pkgName || "the app") + " and " +
            (otherPkg.name || "the app") + ", " +
            "are both trying to handle ." + ext);
        // Recover by just going with the first handler we saw
        return;
      }
      // Is this handler only registered for, say, "web", and we're building,
      // say, "os"?
      if (sourceHandler.archMatching &&
          !archinfo.matches(inputSourceArch.arch, sourceHandler.archMatching)) {
        return;
      }
      allHandlersWithPkgs[ext] = {
        pkgName: otherPkg.name,
        handler: sourceHandler.handler
      };
      sourceExtensions[ext] = !!sourceHandler.isTemplate;
    });

    // Iterate over the compiler plugins.
    _.each(otherPkg.sourceProcessors.compiler, function (compilerPlugin, id) {
      _.each(compilerPlugin.extensions, function (ext) {
        if (_.has(allHandlersWithPkgs, ext) ||
            _.has(compilerPluginsByExtension, ext)) {
          buildmessage.error(
            "conflict: two packages included in " +
              (inputSourceArch.pkg.name || "the app") + ", " +
              (allHandlersWithPkgs[ext].pkgName || "the app") + " and " +
              (otherPkg.name || "the app") + ", " +
              "are both trying to handle ." + ext);
          // Recover by just going with the first one we found.
          return;
        }
        compilerPluginsByExtension[ext] = compilerPlugin;
        sourceExtensions[ext] = compilerPlugin.isTemplate;
      });
    });

    // Iterate over the linters
    _.each(otherPkg.sourceProcessors.linter, function (linterPlugin, id) {
      _.each(linterPlugin.extensions, function (ext) {
        linterPluginsByExtension[ext] = linterPluginsByExtension[ext] || [];
        linterPluginsByExtension[ext].push(linterPlugin);
      });
    });
  });

  // *** Determine source files
  // Note: sourceExtensions does not include leading dots
  // Note: the getSourcesFunc function isn't expected to add its
  // source files to watchSet; rather, the watchSet is for other
  // things that the getSourcesFunc consulted (such as directory
  // listings or, in some hypothetical universe, control files) to
  // determine its source files.
  var sourceItems = inputSourceArch.getSourcesFunc(sourceExtensions, watchSet);

  if (nodeModulesPath) {
    // If this slice has node modules, we should consider the shrinkwrap file
    // to be part of its inputs. (This is a little racy because there's no
    // guarantee that what we read here is precisely the version that's used,
    // but it's better than nothing at all.)
    //
    // Note that this also means that npm modules used by plugins will get
    // this npm-shrinkwrap.json in their pluginDependencies (including for all
    // packages that depend on us)!  This is good: this means that a tweak to
    // an indirect dependency of the coffee-script npm module used by the
    // coffeescript package will correctly cause packages with *.coffee files
    // to be rebuilt.
    var shrinkwrapPath = nodeModulesPath.replace(
        /node_modules$/, 'npm-shrinkwrap.json');
    watch.readAndWatchFile(watchSet, shrinkwrapPath);
  }

  // *** Process each source file
  var addAsset = function (contents, relPath, hash) {
    // XXX hack
    if (! inputSourceArch.pkg.name)
      relPath = relPath.replace(/^(private|public)\//, '');

    resources.push({
      type: "asset",
      data: contents,
      path: relPath,
      servePath: colonConverter.convert(
        files.pathJoin(inputSourceArch.pkg.serveRoot, relPath)),
      hash: hash
    });
  };

  var convertSourceMapPaths = function (sourcemap, f) {
    if (! sourcemap) {
      // Don't try to convert it if it doesn't exist
      return sourcemap;
    }

    var srcmap = JSON.parse(sourcemap);
    srcmap.sources = _.map(srcmap.sources, f);
    return JSON.stringify(srcmap);
  };

  var wrappedSourceItems = _.map(sourceItems, function (source) {
    var fileWatchSet = new watch.WatchSet;
    // readAndWatchFileWithHash returns an object carrying a buffer with the
    // file-contents. The buffer contains the original data of the file (no EOL
    // transforms from the tools/files.js part).
    // We don't put this into the unibuild's watchSet immediately since we want
    // to avoid putting it there if it turns out not to be relevant to our
    // arch.
    var absPath = files.pathResolve(
      inputSourceArch.pkg.sourceRoot, source.relPath);
    var file = watch.readAndWatchFileWithHash(fileWatchSet, absPath);

    Console.nudge(true);

    return {
      relPath: source.relPath,
      watchset: fileWatchSet,
      contents: file.contents,
      hash: file.hash,
      source: source,
      'package': isopk.name
    };
  });

  runLinters(inputSourceArch, isopackCache, wrappedSourceItems, linterPluginsByExtension);

  _.each(wrappedSourceItems, function (wrappedSource) {
    var source = wrappedSource.source;
    var relPath = source.relPath;
    var fileOptions = _.clone(source.fileOptions) || {};
    var absPath = files.pathResolve(inputSourceArch.pkg.sourceRoot, relPath);
    var filename = files.pathBasename(relPath);
    var contents = wrappedSource.contents;
    var hash = wrappedSource.hash;
    var fileWatchSet = wrappedSource.watchset;

    Console.nudge(true);

    if (contents === null) {
      // It really sucks to put this check here, since this isn't publish
      // code...
      if (source.relPath.match(/:/)) {
        buildmessage.error(
          "Couldn't build this package on Windows due to the following file " +
          "with a colon -- " + source.relPath + ". Please rename and " +
          "and re-publish the package.");
      } else {
        buildmessage.error("File not found: " + source.relPath);
      }

      // recover by ignoring (but still watching the file)
      watchSet.merge(fileWatchSet);
      return;
    }

    // Find the handler for source files with this extension.
    var handler = null;
    var isBuildPluginSource = false;
    if (! fileOptions.isAsset) {
      var parts = filename.split('.');
      // don't use iteration functions, so we can return/break
      for (var i = 1; i < parts.length; i++) {
        var extension = parts.slice(i).join('.');
        if (_.has(compilerPluginsByExtension, extension)) {
          var compilerPlugin = compilerPluginsByExtension[extension];
          if (! compilerPlugin.relevantForArch(inputSourceArch.arch)) {
            // This file is for a compiler plugin but not for this arch. Skip
            // it, and don't even watch it.  (eg, skip CSS preprocessor files on
            // the server.)
            return;
          }
          isBuildPluginSource = true;
          break;
        }
        if (_.has(allHandlersWithPkgs, extension)) {
          handler = allHandlersWithPkgs[extension].handler;
          break;
        }
      }
    }

    // OK, this is relevant to this arch, so watch it.
    watchSet.merge(fileWatchSet);

    if (isBuildPluginSource) {
      // This is source used by a new-style compiler plugin; it will be fully
      // processed later in the bundler.
      resources.push({
        type: "source",
        data: contents,
        path: relPath,
        hash: hash
      });
      return;
    }

    if (! handler) {
      // If we don't have an extension handler, serve this file as a
      // static resource on the client, or ignore it on the server.
      //
      // XXX This is pretty confusing, especially if you've
      // accidentally forgotten a plugin -- revisit?
      addAsset(contents, relPath, hash);
      return;
    }

    // This object is called a #CompileStep and it's the interface
    // to plugins that define new source file handlers (eg,
    // Coffeescript).
    //
    // Fields on CompileStep:
    //
    // - arch: the architecture for which we are building
    // - inputSize: total number of bytes in the input file
    // - inputPath: the filename and (relative) path of the input
    //   file, eg, "foo.js". We don't provide a way to get the full
    //   path because you're not supposed to read the file directly
    //   off of disk. Instead you should call read(). That way we
    //   can ensure that the version of the file that you use is
    //   exactly the one that is recorded in the dependency
    //   information.
    // - pathForSourceMap: If this file is to be included in a source map,
    //   this is the name you should use for it in the map.
    // - rootOutputPath: on web targets, for resources such as
    //   stylesheet and static assets, this is the root URL that
    //   will get prepended to the paths you pick for your output
    //   files so that you get your own namespace, for example
    //   '/packages/foo'. null on non-web targets
    // - fileOptions: any options passed to "api.addFiles"; for
    //   use by the plugin. The built-in "js" plugin uses the "bare"
    //   option for files that shouldn't be wrapped in a closure.
    // - declaredExports: An array of symbols exported by this unibuild, or null
    //   if it may not export any symbols (eg, test unibuilds). This is used by
    //   CoffeeScript to ensure that it doesn't close over those symbols, eg.
    // - read(n): read from the input file. If n is given it should
    //   be an integer, and you will receive the next n bytes of the
    //   file as a Buffer. If n is omitted you get the rest of the
    //   file.
    // - appendDocument({ section: "head", data: "my markup" })
    //   Browser targets only. Add markup to the "head" or "body"
    //   Web targets only. Add markup to the "head" or "body"
    //   section of the document.
    // - addStylesheet({ path: "my/stylesheet.css", data: "my css",
    //                   sourceMap: "stringified json sourcemap"})
    //   Web targets only. Add a stylesheet to the
    //   document. 'path' is a requested URL for the stylesheet that
    //   may or may not ultimately be honored. (Meteor will add
    //   appropriate tags to cause the stylesheet to be loaded. It
    //   will be subject to any stylesheet processing stages in
    //   effect, such as minification.)
    // - addJavaScript({ path: "my/program.js", data: "my code",
    //                   sourcePath: "src/my/program.js",
    //                   bare: true })
    //   Add JavaScript code, which will be namespaced into this
    //   package's environment (eg, it will see only the exports of
    //   this package's imports), and which will be subject to
    //   minification and so forth. Again, 'path' is merely a hint
    //   that may or may not be honored. 'sourcePath' is the path
    //   that will be used in any error messages generated (eg,
    //   "foo.js:4:1: syntax error"). It must be present and should
    //   be relative to the project root. Typically 'inputPath' will
    //   do handsomely. "bare" means to not wrap the file in
    //   a closure, so that its vars are shared with other files
    //   in the module.
    // - addAsset({ path: "my/image.png", data: Buffer })
    //   Add a file to serve as-is over HTTP (web targets) or
    //   to include as-is in the bundle (os targets).
    //   This time `data` is a Buffer rather than a string. For
    //   web targets, it will be served at the exact path you
    //   request (concatenated with rootOutputPath). For server
    //   targets, the file can be retrieved by passing path to
    //   Assets.getText or Assets.getBinary.
    // - error({ message: "There's a problem in your source file",
    //           sourcePath: "src/my/program.ext", line: 12,
    //           column: 20, func: "doStuff" })
    //   Flag an error -- at a particular location in a source
    //   file, if you like (you can even indicate a function name
    //   to show in the error, like in stack traces). sourcePath,
    //   line, column, and func are all optional.
    //
    // XXX for now, these handlers must only generate portable code
    // (code that isn't dependent on the arch, other than 'web'
    // vs 'os') -- they can look at the arch that is provided
    // but they can't rely on the running on that particular arch
    // (in the end, an arch-specific unibuild will be emitted only if
    // there are native node modules). Obviously this should
    // change. A first step would be a setOutputArch() function
    // analogous to what we do with native node modules, but maybe
    // what we want is the ability to ask the plugin ahead of time
    // how specific it would like to force unibuilds to be.
    //
    // XXX we handle encodings in a rather cavalier way and I
    // suspect we effectively end up assuming utf8. We can do better
    // than that!
    //
    // XXX addAsset probably wants to be able to set MIME type and
    // also control any manifest field we deem relevant (if any)
    //
    // XXX Some handlers process languages that have the concept of
    // include files. These are problematic because we need to
    // somehow instrument them to get the names and hashs of all of
    // the files that they read for dependency tracking purposes. We
    // don't have an API for that yet, so for now we provide a
    // workaround, which is that _fullInputPath contains the full
    // absolute path to the input files, which allows such a plugin
    // to set up its include search path. It's then on its own for
    // registering dependencies (for now..)
    //
    // XXX in the future we should give plugins an easy and clean
    // way to return errors (that could go in an overall list of
    // errors experienced across all files)
    var readOffset = 0;

    /**
     * The comments for this class aren't used to generate docs right now.
     * The docs live in the GitHub Wiki at: https://github.com/meteor/meteor/wiki/CompileStep-API-for-Build-Plugin-Source-Handlers
     * @class CompileStep
     * @summary The object passed into Plugin.registerSourceHandler
     * @global
     */
    var compileStep = {

      /**
       * @summary The total number of bytes in the input file.
       * @memberOf CompileStep
       * @instance
       * @type {Integer}
       */
      inputSize: contents.length,

      /**
       * @summary The filename and relative path of the input file.
       * Please don't use this filename to read the file from disk, instead
       * use [compileStep.read](CompileStep-read).
       * @type {String}
       * @instance
       * @memberOf CompileStep
       */
      inputPath: files.convertToOSPath(relPath, true),

      /**
       * @summary The filename and absolute path of the input file.
       * Please don't use this filename to read the file from disk, instead
       * use [compileStep.read](CompileStep-read).
       * @type {String}
       * @instance
       * @memberOf CompileStep
       */
      fullInputPath: files.convertToOSPath(absPath),

      // The below is used in the less and stylus packages... so it should be
      // public API.
      _fullInputPath: files.convertToOSPath(absPath), // avoid, see above..

      // Used for one optimization. Don't rely on this otherwise.
      _hash: hash,

      // XXX duplicates _pathForSourceMap() in linker
      /**
       * @summary If you are generating a sourcemap for the compiled file, use
       * this path for the original file in the sourcemap.
       * @type {String}
       * @memberOf CompileStep
       * @instance
       */
      pathForSourceMap: files.convertToOSPath(
        inputSourceArch.pkg.name ?  inputSourceArch.pkg.name + "/" + relPath :
                                    files.pathBasename(relPath), true),

      // null if this is an app. intended to be used for the sources
      // dictionary for source maps.
      /**
       * @summary The name of the package in which the file being built exists.
       * @type {String}
       * @memberOf CompileStep
       * @instance
       */
      packageName: inputSourceArch.pkg.name,

      /**
       * @summary On web targets, this will be the root URL prepended
       * to the paths you pick for your output files. For example,
       * it could be "/packages/my-package".
       * @type {String}
       * @memberOf CompileStep
       * @instance
       */
      rootOutputPath: files.convertToOSPath(
        inputSourceArch.pkg.serveRoot, true),

      /**
       * @summary The architecture for which we are building. Can be "os",
       * "web.browser", or "web.cordova".
       * @type {String}
       * @memberOf CompileStep
       * @instance
       */
      arch: inputSourceArch.arch,

      /**
       * @deprecated in 0.9.4
       * This is a duplicate API of the above, we don't need it.
       */
      archMatches: function (pattern) {
        return archinfo.matches(inputSourceArch.arch, pattern);
      },

      /**
       * @summary Any options passed to "api.addFiles".
       * @type {Object}
       * @memberOf CompileStep
       * @instance
       */
      fileOptions: fileOptions,

      /**
       * @summary The list of exports that the current package has defined.
       * Can be used to treat those symbols differently during compilation.
       * @type {Object}
       * @memberOf CompileStep
       * @instance
       */
      declaredExports: _.pluck(inputSourceArch.declaredExports, 'name'),

      /**
       * @summary Read from the input file. If `n` is specified, returns the
       * next `n` bytes of the file as a Buffer. XXX not sure if this actually
       * returns a String sometimes...
       * @param  {Integer} [n] The number of bytes to return.
       * @instance
       * @memberOf CompileStep
       * @returns {Buffer}
       */
      read: function (n) {
        if (n === undefined || readOffset + n > contents.length)
          n = contents.length - readOffset;
        var ret = contents.slice(readOffset, readOffset + n);
        readOffset += n;
        return ret;
      },

      /**
       * @summary Works in web targets only. Add markup to the `head` or `body`
       * section of the document.
       * @param  {Object} options
       * @param {String} options.section Which section of the document should
       * be appended to. Can only be "head" or "body".
       * @param {String} options.data The content to append.
       * @memberOf CompileStep
       * @instance
       */
      addHtml: function (options) {
        if (! archinfo.matches(inputSourceArch.arch, "web"))
          throw new Error("Document sections can only be emitted to " +
                          "web targets");
        if (options.section !== "head" && options.section !== "body")
          throw new Error("'section' must be 'head' or 'body'");
        if (typeof options.data !== "string")
          throw new Error("'data' option to appendDocument must be a string");
        resources.push({
          type: options.section,
          data: new Buffer(files.convertToStandardLineEndings(options.data), 'utf8')
        });
      },

      /**
       * @deprecated in 0.9.4
       */
      appendDocument: function (options) {
        this.addHtml(options);
      },

      /**
       * @summary Web targets only. Add a stylesheet to the document.
       * @param {Object} options
       * @param {String} path The requested path for the added CSS, may not be
       * satisfied if there are path conflicts.
       * @param {String} data The content of the stylesheet that should be
       * added.
       * @param {String} sourceMap A stringified JSON sourcemap, in case the
       * stylesheet was generated from a different file.
       * @memberOf CompileStep
       * @instance
       */
      addStylesheet: function (options) {
        if (! archinfo.matches(inputSourceArch.arch, "web"))
          throw new Error("Stylesheets can only be emitted to " +
                          "web targets");
        if (typeof options.data !== "string")
          throw new Error("'data' option to addStylesheet must be a string");
        resources.push({
          type: "css",
          refreshable: true,
          data: new Buffer(files.convertToStandardLineEndings(options.data), 'utf8'),
          servePath: colonConverter.convert(
            files.pathJoin(
              inputSourceArch.pkg.serveRoot,
              files.convertToStandardPath(options.path, true))),
          sourceMap: convertSourceMapPaths(options.sourceMap,
                                           files.convertToStandardPath)
        });
      },

      /**
       * @summary Add JavaScript code. The code added will only see the
       * namespaces imported by this package as runtime dependencies using
       * ['api.use'](#PackageAPI-use). If the file being compiled was added
       * with the bare flag, the resulting JavaScript won't be wrapped in a
       * closure.
       * @param {Object} options
       * @param {String} options.path The path at which the JavaScript file
       * should be inserted, may not be honored in case of path conflicts.
       * @param {String} options.data The code to be added.
       * @param {String} options.sourcePath The path that will be used in
       * any error messages generated by this file, e.g. `foo.js:4:1: error`.
       * @memberOf CompileStep
       * @instance
       */
      addJavaScript: function (options) {
        if (typeof options.data !== "string")
          throw new Error("'data' option to addJavaScript must be a string");
        if (typeof options.sourcePath !== "string")
          throw new Error("'sourcePath' option must be supplied to addJavaScript. Consider passing inputPath.");

        // By default, use fileOptions for the `bare` option but also allow
        // overriding it with the options
        var bare = fileOptions.bare;
        if (options.hasOwnProperty("bare")) {
          bare = options.bare;
        }

        js.push({
          source: files.convertToStandardLineEndings(options.data),
          sourcePath: files.convertToStandardPath(options.sourcePath, true),
          servePath: files.pathJoin(
            inputSourceArch.pkg.serveRoot,
            files.convertToStandardPath(options.path, true)),
          bare: !! bare,
          sourceMap: convertSourceMapPaths(options.sourceMap,
                                           files.convertToStandardPath),
          sourceHash: options._hash
        });
      },

      /**
       * @summary Add a file to serve as-is to the browser or to include on
       * the browser, depending on the target. On the web, it will be served
       * at the exact path requested. For server targets, it can be retrieved
       * using `Assets.getText` or `Assets.getBinary`.
       * @param {Object} options
       * @param {String} path The path at which to serve the asset.
       * @param {Buffer|String} data The data that should be placed in
       * the file.
       * @memberOf CompileStep
       * @instance
       */
      addAsset: function (options) {
        if (! (options.data instanceof Buffer)) {
          if (_.isString(options.data)) {
            options.data = new Buffer(options.data);
          } else {
            throw new Error("'data' option to addAsset must be a Buffer or String.");
          }
        }

        addAsset(options.data, files.convertToStandardPath(options.path, true));
      },

      /**
       * @summary Display a build error.
       * @param  {Object} options
       * @param {String} message The error message to display.
       * @param {String} [sourcePath] The path to display in the error message.
       * @param {Integer} line The line number to display in the error message.
       * @param {String} func The function name to display in the error message.
       * @memberOf CompileStep
       * @instance
       */
      error: function (options) {
        buildmessage.error(options.message || ("error building " + relPath), {
          file: options.sourcePath,
          line: options.line ? options.line : undefined,
          column: options.column ? options.column : undefined,
          func: options.func ? options.func : undefined
        });
      }
    };

    try {
      (buildmessage.markBoundary(handler))(compileStep);
    } catch (e) {
      e.message = e.message + " (compiling " + relPath + ")";
      buildmessage.exception(e);

      // Recover by ignoring this source file (as best we can -- the
      // handler might already have emitted resources)
    }
  });

  // *** Run Phase 1 link

  // Load jsAnalyze from the js-analyze package... unless we are the
  // js-analyze package, in which case never mind. (The js-analyze package's
  // default unibuild is not allowed to depend on anything!)
  var jsAnalyze = null;
  if (! _.isEmpty(js) && inputSourceArch.pkg.name !== "js-analyze") {
    jsAnalyze = isopackets.load('js-analyze')['js-analyze'].JSAnalyze;
  }

  var results = linker.prelink({
    inputFiles: js,
    useGlobalNamespace: isApp,
    // I was confused about this, so I am leaving a comment -- the
    // combinedServePath is either [pkgname].js or [pluginName]:plugin.js.
    // XXX: If we change this, we can get rid of source arch names!
    combinedServePath: isApp ? null :
      "/packages/" + colonConverter.convert(
        inputSourceArch.pkg.name +
        (inputSourceArch.kind === "main" ? "" : (":" + inputSourceArch.kind)) +
        ".js"),
    name: inputSourceArch.pkg.name || null,
    declaredExports: _.pluck(inputSourceArch.declaredExports, 'name'),
    jsAnalyze: jsAnalyze,
    noLineNumbers: noLineNumbers
  });

  // *** Determine captured variables
  var packageVariables = [];
  var packageVariableNames = {};
  _.each(inputSourceArch.declaredExports, function (symbol) {
    if (_.has(packageVariableNames, symbol.name))
      return;
    packageVariables.push({
      name: symbol.name,
      export: symbol.testOnly? "tests" : true
    });
    packageVariableNames[symbol.name] = true;
  });
  _.each(results.assignedVariables, function (name) {
    if (_.has(packageVariableNames, name))
      return;
    packageVariables.push({
      name: name
    });
    packageVariableNames[name] = true;
  });

  // *** Consider npm dependencies and portability
  var arch = inputSourceArch.arch;
  if (arch === "os" && ! isPortable) {
    // Contains non-portable compiled npm modules, so set arch correctly
    arch = archinfo.host();
  }
  if (! archinfo.matches(arch, "os")) {
    // npm modules only work on server architectures
    nodeModulesPath = undefined;
  }

  // *** Output unibuild object
  isopk.addUnibuild({
    kind: inputSourceArch.kind,
    arch: arch,
    uses: inputSourceArch.uses,
    implies: inputSourceArch.implies,
    watchSet: watchSet,
    nodeModulesPath: nodeModulesPath,
    prelinkFiles: results.files,
    packageVariables: packageVariables,
    resources: resources
  });

  return {
    pluginProviderPackageNames: pluginProviderPackageNames
  };
};

var runLinters = function (
  inputSourceArch,
  isopackCache,
  wrappedSourceItems,
  linterPluginsByExtension) {
  // For linters, figure out what are the global imports from other packages
  // that we use directly, or are implied.
  var globalImports = ['Package', 'Assets', 'Npm'];
  compiler.eachUsedUnibuild({
    dependencies: inputSourceArch.uses,
    arch: inputSourceArch.arch,
    isopackCache: isopackCache,
    skipUnordered: true,
    skipDebugOnly: true
  }, function (unibuild) {
    if (unibuild.pkg.name === inputSourceArch.pkg.name)
      return;
    _.each(unibuild.packageVariables, function (symbol) {
      if (symbol.export === true)
        globalImports.push(symbol.name);
    });
  });

  // For each file choose the longest extension handled by linters.
  var longestMatchingExt = {};
  _.each(wrappedSourceItems, function (wrappedSource) {
    var filename = files.pathBasename(wrappedSource.relPath);
    var parts = filename.split('.');
    for (var i = 1; i < parts.length; i++) {
      var extension = parts.slice(i).join('.');
      if (_.has(linterPluginsByExtension, extension)) {
        longestMatchingExt[wrappedSource.relPath] = extension;
        break;
      }
    }
  });

  // Run linters on files.
  _.each(linterPluginsByExtension, function (linters, ext) {
    var sourcesToLint = [];
    _.each(wrappedSourceItems, function (wrappedSource) {
      var relPath = wrappedSource.relPath;
      var hash = wrappedSource.hash;
      var fileWatchSet = wrappedSource.watchset;
      var source = wrappedSource.source;

      // only run linters matching the longest handled extension
      if (longestMatchingExt[relPath] !== ext)
        return;

      sourcesToLint.push(new linterPluginModule.LintingFile(wrappedSource));
    });

    _.each(linters, function (linterDef) {
      // skip linters not relevant to the arch we are compiling for
      if (! linterDef.relevantForArch(inputSourceArch.arch))
        return;

      var linter = linterDef.instantiatePlugin();
      buildmessage.enterJob({
        title: "linting files with " + linterDef.isopack.name
      }, function () {
        try {
          var markedLinter = buildmessage.markBoundary(linter.run.bind(linter));
          markedLinter(sourcesToLint, globalImports);
        } catch (e) {
          buildmessage.exception(e);
        }
      });
    });
  });
};

// Iterates over each in options.dependencies as well as unibuilds implied by
// them. The packages in question need to already be built and in
// options.isopackCache.
compiler.eachUsedUnibuild = function (
  options, callback) {
  buildmessage.assertInCapture();
  var dependencies = options.dependencies;
  var arch = options.arch;
  var isopackCache = options.isopackCache;

  var acceptableWeakPackages = options.acceptableWeakPackages || {};

  var processedUnibuildId = {};
  var usesToProcess = [];
  _.each(dependencies, function (use) {
    if (options.skipUnordered && use.unordered)
      return;
    if (use.weak && !_.has(acceptableWeakPackages, use.package))
      return;
    usesToProcess.push(use);
  });

  while (! _.isEmpty(usesToProcess)) {
    var use = usesToProcess.shift();

    var usedPackage = isopackCache.getIsopack(use.package);

    // Ignore this package if we were told to skip debug-only packages and it is
    // debug-only.
    if (usedPackage.debugOnly && options.skipDebugOnly)
      continue;

    var unibuild = usedPackage.getUnibuildAtArch(arch);
    if (!unibuild) {
      // The package exists but there's no unibuild for us. A buildmessage has
      // already been issued. Recover by skipping.
      continue;
    }

    if (_.has(processedUnibuildId, unibuild.id))
      continue;
    processedUnibuildId[unibuild.id] = true;

    callback(unibuild, {
      unordered: !!use.unordered,
      weak: !!use.weak
    });

    _.each(unibuild.implies, function (implied) {
      usesToProcess.push(implied);
    });
  }
};


if (Meteor.isClient) {
  Template.page.nodespec = function (fn) {
    var parts = [fn()];
    var replaceParts = function(regex, replacementFunc) {
      var newParts = [];
      _.each(parts, function (part) {
        if (typeof part !== 'string') {
          newParts.push(part);
          return;
        }
        regex.lastIndex = 0;
        var charsTaken = 0;
        var matchResult;
        while ((matchResult = regex.exec(part))) {
          var matchIndex = matchResult.index;
          if (matchIndex > charsTaken)
            newParts.push(part.substring(charsTaken, matchIndex));
          charsTaken = regex.lastIndex;
          var replacementParts = replacementFunc(matchResult);
          newParts.push.apply(newParts, _.toArray(replacementParts));
        }
        if (charsTaken < part.length)
          newParts.push(part.slice(charsTaken));
      });
      parts = newParts;
    };

    parts.unshift(['
']);
    parts.push(['
']);
    replaceParts(/".*?"/g, function (match) {
      return [['', Handlebars._escape(match[0]), '']];
    });
    replaceParts(/`(.*?)`/g, function (match) {
      return [['', Handlebars._escape(match[1]), '']];
    });
    replaceParts(/[A-Z]{3,}/g, function (match) {
      return [['', Handlebars._escape(match[0]), '']];
    });
    replaceParts(/[a-z]\w*/g, function (match) {
      return [['', Handlebars._escape(match[0]), '']];
    });
    replaceParts(/[\[\]()|.,*?]/g, function (match) {
      return [[''], match[0], ['']];
    });
    replaceParts(/,/g, function (match) {
      return [[''], match[0], ['']];
    });
    replaceParts(/\|/g, function (match) {
      return [[''], match[0], ['']];
    });

    var html = _.map(parts, function (part) {
      if (typeof part === "string")
        return Handlebars._escape(part);
      return part.join('');
    }).join('');

    return new Handlebars.SafeString(html);
  };

  Template.page.spacer = function () {
    return new Handlebars.SafeString('

');
  };

}


hi
/each}}

hi
/each}}

hi

/each}}

hi

/each}}

some paragraph to fix showdown's four space parsing below.

<i>hi</i>
/each}}

<b><i>hi</i></b>
<b>/each}}</b>

&gt

&gt

&gt

&gt

>

>

&gt;

&gt;

<i>hi</i>
/each}}

<b><i>hi</i></b>
<b>/each}}


#!/bin/bash

# This scripts automates the release process of Meteor Tool.

# Normally, after publishing a new Meteor release from checkout, you need to ssh
# to a machine running every supported platform and publish a build from it.
# This script automates ssh'ing into machines and running the publish command.

set -e
set -u

TEMP_PRIV_KEY=
TEMP_KEY=
SESSION_FILE=

main () {
  if [ $# -ne 1 ]; then
    echo "usage: $0 GITSHA" 1>&2
    echo "The passed commit is checked out and published from the remote machines." 1>&2
    exit 1
  fi
  GITSHA=$1

  ADMIN_DIR="`dirname "$0"`"
  SCRIPTS_DIR="`dirname "$ADMIN_DIR"`"
  CHECKOUT_DIR="`dirname "$SCRIPTS_DIR"`"

  METEOR="$CHECKOUT_DIR/meteor"

  trap 'echo "${red}Login failed.${NC}"; clean_up' EXIT

  echo "${green}Login with a meteor account belonging to MDG."
  echo "A session file will be generated in your checkout and it will be used to"
  echo "publish the release from the remote machines.${NC}"

  SESSION_FILE="$CHECKOUT_DIR/publish-meteor-tool-session"
  env METEOR_SESSION_FILE="$SESSION_FILE" "$METEOR" login

  echo "${green}Login succeeded.${NC}"
  echo
  echo "Run the following commands in separate terminal windows:"
  echo

  # XXX there is no os.windows.x86_64 as we don't build for it at the moment
  PLATFORMS=( os.osx.x86_64 os.linux.x86_64 os.linux.x86_32 os.windows.x86_32 )
  for PLATFORM in ${PLATFORMS[@]}; do
    COMMAND="`dirname $0`/publish-meteor-tool-on-arch.sh $GITSHA $PLATFORM $SESSION_FILE"
    echo $COMMAND
  done

  trap - EXIT
}

clean_up () {
  if [[ "x$SESSION_FILE" != x ]]; then
    echo "Removing used session file."
    rm "$SESSION_FILE"
  fi

  exit 1
}

# '|| true' so that we don't fail on terminals without colors
red=`tput setaf 1 || true`
green=`tput setaf 2 || true`
NC=`tput sgr0 || true`

main $@


var linter = linterDef.instantiatePlugin();

title: "linting files with " + linterDef.isopack.name

var markedLinter = buildmessage.markBoundary(linter.run.bind(linter));

keep replace replace replace replace replace replace replace replace replace replace replace keep keep keep


var selftest = require('../selftest.js');
var Sandbox = selftest.Sandbox;
var files = require('../files.js');
var catalog = require('../catalog.js');

var DEFAULT_RELEASE_TRACK = catalog.DEFAULT_TRACK;

// XXX: Why is this an internet using test? Because our warehouse is a
// hackhackhack. If we clean up the hackhackhackhack, then this does not need
// the internets. (Or, to be more specific: our warehouse code tries to fetch
// the packages from the internet. If we could fool it into using local packages
// instead, or think that it alreayd has the packages, it would be ok). (This is
// because it calls 'create' from a warehouse, to be specific).
selftest.define("springboard", ['checkout', 'net'], function () {
  var s = new Sandbox({
    warehouse: {
      v1: { },
      v2: { recommended: true }
    }
  });
  var run;

  // If run not in an app dir, runs the latest version ...
  run = s.run("--version");
  run.read('Meteor v2\n');
  run.expectEnd();
  run.expectExit(0);

  // ... unless you asked for a different one.
  run = s.run("--version", "--release", DEFAULT_RELEASE_TRACK + "@v1");
  run.read('Meteor v1\n');
  run.expectEnd();
  run.expectExit(0);

  // Apps are created with the latest release ...
  run = s.run("create", "myapp");
  run.waitSecs(5);
  run.expectExit(0);
  s.cd('myapp', function () {
    run = s.run("--version");
    run.read('Meteor v2\n');
    run.expectExit(0);
  });

  // ... unless you asked for a different one.
  run = s.run("create", "myapp2", "--release", DEFAULT_RELEASE_TRACK + "@v1").expectExit(0);
  s.cd('myapp2', function () {
    run = s.run("--version");
    run.read('Meteor v1\n');
    run.expectExit(0);
  });

  // Suppose you ask for a release that doesn't exist.
  s.set('METEOR_TEST_FAIL_RELEASE_DOWNLOAD', 'not-found');
  run = s.run("--release", "weird");
  run.readErr("Meteor weird: unknown release.\n");
  run.expectEnd();
  run.expectExit(1);

  // Suppose you're offline and you ask for a release you don't have
  // cached.
  // XXX On the refreshpolicy branch, we removed some of the support
  // code for this test. Make sure we get it to pass before merging.
  s.set('METEOR_TEST_FAIL_RELEASE_DOWNLOAD', 'offline');
  run = s.run("--release", "weird");
  run.matchErr("offline");
  run.matchErr("weird: unknown release");
  run.expectExit(1);

  // Project asking for nonexistent release.
  s.cd('myapp2', function () {
    s.write(".meteor/release", "strange");
    s.set('METEOR_TEST_FAIL_RELEASE_DOWNLOAD', 'not-found');
    run = s.run();
    run.matchErr("uses Meteor strange");

    run.matchErr(/don't\s+have\s+it\s+either/);
    run.expectExit(1);

    // You're offline and project asks for non-cached release.
    s.set('METEOR_TEST_FAIL_RELEASE_DOWNLOAD', 'offline');
    run = s.run();
    run.matchErr("offline");
    run.matchErr(/it\s+uses\s+Meteor\s+strange/);
    run.matchErr(/don't\s+have\s+that\s+version/);
    run.matchErr(/of\s+Meteor\s+installed/);
    run.matchErr(/update\s+servers/);
    run.expectExit(1);

    // You create an app from a checkout, and then try to use it from an
    // install without setting a release on it.
    s.unset('METEOR_TEST_FAIL_RELEASE_DOWNLOAD');
    s.write(".meteor/release", "none");
    run = s.run("--requires-release");
    run.matchErr("must specify");
    run.matchErr("permanently set");
    run.expectExit(1);

    // As previous, but you pass --release to manually pick a release.
    run = s.run("--version", "--release", "v1");
    run.expectExit(0);
    run.forbidAll("must specify");
    run.forbidAll("permanently set");

    // You use modern Meteor with a super old release from the dark ages
    // before the .meteor/release file. You get an error.
    s.unlink('.meteor/release');
    run = s.run("--version");
    run.matchErr("does not have a .meteor/release file");
    run.matchErr("edit the .meteor/release file");
    run.expectExit(1);

    // .meteor/release exists but is empty. You get an error.
    s.write(".meteor/release", "\n");
    run = s.run("--version");
    run.matchErr("release file which is empty");
    run.expectExit(1);

    // XXX Test springboard to pre-0.9.0 release
  });
});

// XXX: Why is this an internet using test? Because our warehouse is a
// hackhackhack. If we clean up the hackhackhackhack, then this does not need
// the internets. (Or, to be more specific: our warehouse code tries to fetch
// the packages from the internet. If we could fool it into using local packages
// instead, or think that it already has the packages, it would be ok).
selftest.define("writing versions file", ['checkout', 'net'], function () {
  var s = new Sandbox({
    warehouse: {
      v1: { recommended: true},
      v2: { recommended: true }
    }
  });
  var run;

  // Create an app with the latest release.
  run = s.run("create", "myapp");
  run.waitSecs(15);
  run.expectExit(0);
  s.cd('myapp');
  run = s.run("--version");
  run.read('Meteor v2\n');
  run.expectExit(0);

  // Check the contents of the versions file.
  var versions = s.read('.meteor/versions');
  if (!versions) {
    selftest.fail("Versions file NOT written in new app.");
  }

  // Remove the versions file.
  s.unlink('.meteor/versions');

  // Run with --release, do not change versions file.
  run = s.run("list", "--release", "v1");
  run.expectExit(0);
  versions = s.read('.meteor/versions');
  if (versions) {
    selftest.fail("Versions file written with --release.");
  }

  // Update with --release.
  run = s.run("update", "--release", "v1");
  run.expectExit(0);

  // version file should exist.
  versions = s.read('.meteor/versions');
  if (!versions) {
    selftest.fail("Versions file NOT written after update");
  }

});

selftest.define("checkout", ['checkout'], function () {
  var s = new Sandbox;
  var run;

  // Can't specify a release when running Meteor from a checkout
  run = s.run("--release", "v1");
  run.waitSecs(5);
  run.matchErr("Can't specify");
  run.expectExit(1);

  // You get a warning banner when the checkout overrides the release
  // that an app is pinned to
  s.createApp('myapp', 'standard-app');
  s.cd('myapp', function () {
    s.write(".meteor/release", "something");
    run = s.run("list");
    run.readErr("=> Running Meteor from a checkout");
    run.matchErr("project version");
    run.matchErr("(Meteor something)\n");
    run.expectExit(0);
  });
});

selftest.define("download and springboard to pre-0.9.0 release", ['net', 'slow'], function () {
  var s, run;

  if (files.inCheckout())
    s = new Sandbox({ warehouse: { v1: { tools: 'tools1', latest: true } } });
  else
    s = new Sandbox;

  // End-to-end, online test of downloading and springboarding. This
  // release was built from the
  // 'release/release-used-to-test-springboarding' tag in GitHub. All
  // it does is print this string and exit.
  run = s.run("--release", "release-used-to-test-springboarding");
  run.waitSecs(1000);

  if (process.platform === "win32") {
    run.matchErr("Meteor on Windows does not support");
  } else {
    run.match("THIS IS A FAKE RELEASE ONLY USED TO TEST ENGINE SPRINGBOARDING");
  }

  run.expectExit();
});

selftest.define("unknown release", [], function () {
  var s = new Sandbox({
    warehouse: {
      v2: { recommended: true }
    }
  });
 s.set("METEOR_OFFLINE_CATALOG", "t");
  var run;

  s.createApp('myapp', 'packageless', { dontPrepareApp: true });
  s.cd('myapp');
  run = s.run("--release", "bad");
  run.matchErr("Meteor bad: unknown release");

  // METEOR in the release file.
  s.write('.meteor/release', DEFAULT_RELEASE_TRACK + "@0.9-bad");
  run = s.run();
  run.matchErr(
    /This\s+project\s+says\s+that\s+it\s+uses\s+Meteor\s+0.9-bad,\s+but/);

  // No METEOR in the release file.
  s.write('.meteor/release', "0.9.x-bad");
  run = s.run();
  run.matchErr(
    /This\s+project\s+says\s+that\s+it\s+uses\s+Meteor\s+0.9.x-bad,\s+but/);

  // Non-standard track
  s.write('.meteor/release', "FOO@bad");
  run = s.run();
  run.matchErr(
    /This\s+project\s+says\s+that\s+it\s+uses\s+Meteor\s+release\s+FOO@bad,\s+but/);

});


var Empty = {
};
module.exports = Empty;


var CS = ConstraintSolver;
var PV = PackageVersion;

var pvkey = function (pkg, version) {
  return pkg + " " + version;
};

// Stores the Dependencies for each known PackageAndVersion.
CS.CatalogCache = function () {
  // String(PackageAndVersion) -> String -> Dependency.
  // For example, "foo 1.0.0" -> "bar" -> Dependency.fromString("?bar@1.0.2").
  this._dependencies = {};
  // A map derived from the keys of _dependencies, for ease of iteration.
  // "foo" -> ["1.0.0", ...]
  // Versions in the array are unique but not sorted, unless the `.sorted`
  // property is set on the array.  The array is never empty.
  this._versions = {};
};

CS.CatalogCache.prototype.hasPackageVersion = function (pkg, version) {
  return _.has(this._dependencies, pvkey(pkg, version));
};

CS.CatalogCache.prototype.addPackageVersion = function (p, v, deps) {
  check(p, String);
  check(v, String);
  // `deps` must not have any duplicate values of `.packageConstraint.package`
  check(deps, [CS.Dependency]);

  var key = pvkey(p, v);
  if (_.has(this._dependencies, key)) {
    throw new Error("Already have an entry for " + key);
  }

  if (! _.has(this._versions, p)) {
    this._versions[p] = [];
  }
  this._versions[p].push(v);
  this._versions[p].sorted = false;

  var depsByPackage = {};
  this._dependencies[key] = depsByPackage;
  _.each(deps, function (d) {
    var p2 = d.packageConstraint.package;
    if (_.has(depsByPackage, p2)) {
      throw new Error("Can't have two dependencies on " + p2 +
                      " in " + key);
    }
    depsByPackage[p2] = d;
  });
};

// Returns the dependencies of a (package, version), stored in a map.
// The values are Dependency objects; the key for `d` is
// `d.packageConstraint.package`.  (Don't mutate the map.)
CS.CatalogCache.prototype.getDependencyMap = function (p, v) {
  var key = pvkey(p, v);
  if (! _.has(this._dependencies, key)) {
    throw new Error("No entry for " + key);
  }
  return this._dependencies[key];
};

// Returns an array of version strings, sorted, possibly empty.
// (Don't mutate the result.)
CS.CatalogCache.prototype.getPackageVersions = function (pkg) {
  var result = (_.has(this._versions, pkg) ?
                this._versions[pkg] : []);
  if ((!result.length) || result.sorted) {
    return result;
  } else {
    // sort in place, and record so that we don't sort redundantly
    // (we'll sort again if more versions are pushed onto the array)
    result.sort(PV.compare);
    result.sorted = true;
    return result;
  }
};

CS.CatalogCache.prototype.hasPackage = function (pkg) {
  return _.has(this._versions, pkg);
};

CS.CatalogCache.prototype.toJSONable = function () {
  var self = this;
  var data = {};
  _.each(self._dependencies, function (depsByPackage, key) {
    // depsByPackage is a map of String -> Dependency.
    // Map over the values to get an array of String.
    data[key] = _.map(depsByPackage, function (dep) {
      return dep.toString();
    });
  });
  return { data: data };
};

CS.CatalogCache.fromJSONable = function (obj) {
  check(obj, { data: Object });

  var cache = new CS.CatalogCache();
  _.each(obj.data, function (depsArray, pv) {
    check(depsArray, [String]);
    pv = CS.PackageAndVersion.fromString(pv);
    cache.addPackageVersion(
      pv.package, pv.version,
      _.map(depsArray, function (str) {
        return CS.Dependency.fromString(str);
      }));
  });
  return cache;
};

// Calls `iter` on each PackageAndVersion, with the second argument being
// a map from package name to Dependency.  If `iter` returns true,
// iteration is stopped.  There's no particular order to the iteration.
CS.CatalogCache.prototype.eachPackageVersion = function (iter) {
  var self = this;
  _.find(self._dependencies, function (value, key) {
    var stop = iter(CS.PackageAndVersion.fromString(key), value);
    return stop;
  });
};

// Calls `iter` on each package name, with the second argument being
// a list of versions present for that package (unique and sorted).
// If `iter` returns true, iteration is stopped.
ConstraintSolver.CatalogCache.prototype.eachPackage = function (iter) {
  var self = this;
  _.find(_.keys(self._versions), function (key) {
    var stop = iter(key, self.getPackageVersions(key));
    return stop;
  });
};


.codeMirrorContainer {
font-size: 12px;
line-height: 1.25;
overflow: hidden;
position: relative;


/*******************************************************************************

    uBlock Origin - a browser extension to block requests.
    Copyright (C) 2014-present Raymond Hill

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see {http://www.gnu.org/licenses/}.

    Home: https://github.com/gorhill/uBlock
*/

// Code below has been imported from uMatrix and modified to fit uBO:
// https://github.com/gorhill/uMatrix/blob/3f8794dd899a05e066c24066c6c0a2515d5c60d2/src/js/contentscript.js#L464-L531

'use strict';

/******************************************************************************/

// https://github.com/gorhill/uMatrix/issues/232
//   Force `display` property, Firefox is still affected by the issue.

(function() {
    let noscripts = document.querySelectorAll('noscript');
    if ( noscripts.length === 0 ) { return; }

    let redirectTimer,
        reMetaContent = /^\s*(\d+)\s*;\s*url=(['"]?)([^'"]+)\2/i,
        reSafeURL = /^https?:\/\//;

    let autoRefresh = function(root) {
        let meta = root.querySelector('meta[http-equiv="refresh"][content]');
        if ( meta === null ) { return; }
        let match = reMetaContent.exec(meta.getAttribute('content'));
        if ( match === null || match[3].trim() === '' ) { return; }

        let url;
        try {
            url = new URL(match[3], document.baseURI);
        } catch(ex) {
            return;
        }

        if ( reSafeURL.test(url.href) === false ) { return; }
        redirectTimer = setTimeout(( ) => {
                location.assign(url.href);
            },
            parseInt(match[1], 10) * 1000 + 1
        );
        meta.parentNode.removeChild(meta);
    };

    let morphNoscript = function(from) {
        if ( /^application\/(?:xhtml\+)?xml/.test(document.contentType) ) {
            let to = document.createElement('span');
            while ( from.firstChild !== null ) {
                to.appendChild(from.firstChild);
            }
            return to;
        }
        let parser = new DOMParser();
        let doc = parser.parseFromString(
            '<span>' + from.textContent + '</span>',
            'text/html'
        );
        return document.adoptNode(doc.querySelector('span'));
    };

    for ( let noscript of noscripts ) {
        let parent = noscript.parentNode;
        if ( parent === null ) { continue; }
        let span = morphNoscript(noscript);
        span.style.setProperty('display', 'inline', 'important');
        if ( redirectTimer === undefined ) {
            autoRefresh(span);
        }
        parent.replaceChild(span, noscript);
    }
})();

/******************************************************************************/


uBlock Origin

extension name.

Konečne efektívny blokovač. Nezaťažuje CPU ani pamäť.

this will be in the Chrome web store: must be 132 characters or less

uBlock₀ — Ovládací panel

English: uBlock₀ — Dashboard

Upozornenie! Máte neuložené zmeny

A warning in the dashboard when navigating away from unsaved changes

Zostať

Label for button to prevent navigating away from unsaved changes

Ignorovať

Label for button to ignore unsaved changes

Nastavenia

appears as tab name in dashboard

Zoznam filtrov

appears as tab name in dashboard

Moje filtre

appears as tab name in dashboard

Moje pravidlá

appears as tab name in dashboard

Biela listina

appears as tab name in dashboard

Klávesové skratky

appears as tab name in dashboard

uBlock₀ — Zaznamenávač

Title for the logger window

O doplnku

appears as tab name in dashboard

Podpora

appears as tab name in dashboard

uBlock₀ — Zobrazenie zdrojov

Title for the asset viewer page

Pokročilé nastavenia

Title for the advanced settings page

Kliknutie: zakázať/povoliť uBlock pre túto stránku.

Ctrl+kliknutie: zakázať uBlock₀ len pre túto stránku.

English: Click: disable/enable uBlock₀ for this site.

Ctrl+click: disable uBlock₀ only on this page.

Kliknutím zakážete uBlock₀ pre túto stránku.

Ctrl+kliknutie zakáže uBlock₀ len pre túto stránku.

Message to be read by screen readers

Kliknutím povolíte uBlock₀ pre túto stránku.

Message to be read by screen readers

zablokované požiadavky

English: requests blocked

na tejto stránke

English: on this page

{{count}} alebo {{percent}}%

Example: 15 (13%)

od inštalácie

English: since install

alebo

English: or

Blokované na tejto stránke

For the new mobile-friendly popup design

Blokované od inštalácie

Pripojené domény

Otvoriť ovládací panel

English: Click to open the dashboard

Prejsť do režimu výberu prvku

Tooltip for the element-zapper icon in the popup panel

Prejsť do režimu výberu prvku

English: Enter element picker mode

Otvoriť Zaznamenávač

Tooltip used for the logger icon in the panel

Nahlásiť problém na tejto webovej stránke

Tooltip used for the 'chat' icon in the panel

Žiadne vyskakovacie okná pre túto stránku

Tooltip for the no-popups per-site switch

Kliknutím zakážete všetky vyskakovacie okná na tejto stránke

Kliknutím povolíte všetky vyskakovacie okná na tejto stránke

Prepnúť blokovanie veľkých multimediálnych prvkov na tejto stránke

Tooltip for the no-large-media per-site switch

Kliknutím zablokovať veľké multimediálne prvky na tejto stránke

Kliknutím povolíte veľké multimediálne prvky na tejto stránke

Prepnúť kozmetické filtrovanie pre túto stránku

Tooltip for the no-cosmetic-filtering per-site switch

Kliknutím zakážete kozmetické filtrovanie na tejto stránke

Kliknutím povolíte kozmetické filtrovanie na tejto stránke

Prepnúť blokovanie vzdialených písiem na tejto stránke

Tooltip for the no-remote-fonts per-site switch

Kliknutím zakážete vzdialené písma pre túto stránku

Kliknutím povolíte vzdialené písma pre túto stránku

Kliknutím úplne zakážete JavaScript na tejto stránke

Tooltip for the no-scripting per-site switch

Kliknutím už nebude úplne zakázaný JavaScript na tejto stránke

Vyskakovacie okná

Caption for the no-popups per-site switch

Veľké mediálne prvky

Caption for the no-large-media per-site switch

Kozmetické filtrovanie

Caption for the no-cosmetic-filtering per-site switch

Vzdialené písma

Caption for the no-remote-fonts per-site switch

JavaScript

Caption for the no-scripting per-site switch

Viac

Label to be used to show popup panel sections

Menej

Label to be used to hide popup panel sections

Globálne pravidlá: tento stĺpec slúži pre pravidlá, ktoré platia pre všetky weby.

Tooltip when hovering the top-most cell of the global-rules column.

Lokálne pravidlá: tento stĺpec slúži pre pravidlá, ktoré platia len pre aktuálny web.
Lokálne pravidlá prepisujú globálne pravidlá.

Tooltip when hovering the top-most cell of the local-rules column.

Kliknutím použijete vaše zmeny.

Tooltip when hovering over the padlock in the dynamic filtering pane.

Kliknutím vrátite vaše zmeny.

Tooltip when hovering over the eraser in the dynamic filtering pane.

všetko

obrázky

z tretej strany

CSS/obrázky tretích strán

vstavané skripty

skripty prvej triedy

skripty tretej triedy

rámy tretej triedy

pripojené domény

appears in popup

{{count}} z {{total}}

appears in popup

Verzia

Example of use: Version 1.26.4

↑: Zvýrazniť riadky, ktoré majú skripty z tretej strany

Tooltip shown when hovering small filtering widget in '3rd-party scripts' cell

↑: Zvýrazniť riadky, ktoré majú rámy z tretej strany

Tooltip shown when hovering small filtering widget in '3rd-party frames' cell

Vytvoriť

English: Create

Vybrať

English: Pick

Ukončiť

English: Quit

Náhľad

Element picker preview mode: will cause the elements matching the current filter to be removed from the page

Sieťové filtre

English: header for a type of filter in the element picker dialog

Kozmetické filtre

English: Cosmetic filters

Kliknutie, Ctrl-kliknutie

English: Click, Ctrl-click

Zablokovať prvok

An entry in the browser's contextual menu

Skryť zástupcov zablokovaných prvkov

English: Hide placeholders of blocked elements

Zobraziť počet zablokovaných požiadaviek na ikone

English: Show the number of blocked requests on the icon

Zakázať tipy pre nástroje

A checkbox in the Settings pane

Používať kontextovú ponuku v prípade potreby

English: Make use of context menu where appropriate

Režim pre farboslepých

English: Color-blind friendly

Vzhľad

Section for controlling user interface appearance

Motív

Label for checkbox to enable a custom dark theme

Vlastná farba motívu

Label for checkbox to pick an accent color

Povoliť podporu cloudového úložiska

Som pokročilý používateľ (povinne prečítať)

Checkbox to let user access advanced, technical features

Zakázať prednačítavanie (zakáže akékoľvek pripojenie pre zablokované sieťové požiadavky)

English:

Zakázať auditovanie hypertextových odkazov

English:

Zabrániť úniku lokálnej IP adresy cez WebRTC

English:

Predvolené správanie

Tieto predvolené správania môžu byť prepísané u jednotlivých stránkach

Vypnúť kozmetické filtrovanie

Blokovať multimediálne prvky väčšie ako {{input:number}} KB

Blokovať vzdialené písma

Zakázať JavaScript

The default state for the per-site no-scripting switch

Zablokovať CSP hlásenia

background information: https://github.com/gorhill/uBlock/issues/3150

Nemaskovať CNAME

background information: https://github.com/uBlockOrigin/uBlock-issues/issues/1513

Pokročilé

Section for controlling advanced-user settings

Funkcie vhodné iba pre pokročilých používateľov.

Description of section controlling advanced-user settings

pokročilé nastavenia

For the tooltip of a link which gives access to advanced settings

Posledná obnova:

English: Last restore:

Posledná záloha:

English: Last backup:

{{netFilterCount}} sieťových filtrov ＋ {{cosmeticFilterCount}} kozmetických filtrov z:

Appears at the top of the _3rd-party filters_ pane

{{used}} použitých z {{total}}

Appears aside each filter list in the _3rd-party filters_ pane

Automaticky aktualizovať zoznamy filtrov.

A checkbox in the _3rd-party filters_ pane

Aktualizovať teraz

A button in the in the _3rd-party filters_ pane

Vyčistiť celú vyrovnávaciu pamäť

Spracovať a vynútiť kozmetické filtre

English: Parse and enforce Adblock+ element hiding filters.

Táto možnosť povoľuje analyzovanie a vynútenie filtrov “skrývajúcich prvky” a kompatibilných s Adblock Plus. Tieto filtre sú prevažne kozmetické. Skrývajú prvky webových stránok, ktoré sú vizuálne otravné a nemôžu byť zablokované filtrovaním sieťových požiadavkov.

Povolenie tejto funkcie zvyšujte nároky uBlock₀ na pamäť.

Describes the purpose of the 'Parse and enforce cosmetic filters' feature.

Ignorovať generické kozmetické filtre

This will cause uBO to ignore all generic cosmetic filters.

Generické kozmetické filtre sú tie kozmetické filtre, ktoré sú určené na použitie na všetkých webových stránkach.
Aj keď ich uBlock₀ používa efektívne, generické kozmetické filtre môžu stále prispievať k zaťaženiu pamäte a procesora na niektorých webových stránkach, a to najmä na veľkých a zložitých.
Zapnutím tejto možnosti sa zníži zaťaženie pamäte a procesora v dôsledku použitia generických kozmetických filtrov pre webové stránky, a taktiež sa znížia nároky samotného rozšírenia uBlock₀ na pamäť.
Odporúča sa povoliť túto možnosť na menej výkonných zariadeniach.

Describes the purpose of the 'Ignore generic cosmetic filters' feature.

Pozastaviť sieťovú aktivitu, kým sa nenačítajú všetky zoznamy filtrov

A checkbox in the 'Filter lists' pane

Zoznamy zablokovaných hostiteľov

English: Lists of blocked hosts

Použiť zmeny

English: Apply changes

Vstavané

Header for the uBlock filters section in 'Filter lists pane'

Reklamy

English: Ads

Súkromie

English: Privacy

Domény malvéru

English: Malware domains

Obťažujúce

The header identifying the filter lists in the category 'annoyances'

Viacúčelové

English: Multipurpose

Regióny, jazyky

English: Regions, languages

Vlastné

English: Custom

Importovať...

The label for the checkbox used to import external filter lists

Jedna URL adresa na riadok. Neplatné URL adresy budú potichu ignorované.

Short information about how to use the textarea to import external filter lists by URL

Zastarané.

used as a tooltip for the out-of-date icon beside a list

zobraziť obsah

used as a tooltip for eye icon beside a list

Posledná aktualizácia: {{ago}}.
Kliknutím vynútite aktualizáciu.

used as a tooltip for the clock icon beside a list

Aktualizácia...

used as a tooltip for the spinner icon beside a list

Chyba siete zabránila aktualizácii zdroja.

used as a tooltip for error icon beside a list

Jeden filter na riadok. Filter môže byť jednoduchý názov hostiteľa alebo filter kompatibilný s Adblock Plus. Riadky začínajúce s <code>!</code> budú ignorované.

Short information about how to create custom filters

Importovať a pripojiť

English: Import and append

Exportovať

English: Export

ublock-moje-statické-filtre_{{datetime}}.txt

English: my-ublock-static-filters_{{datetime}}.txt

Použiť zmeny

English: Apply changes

Trvalé pravidlá

header

Dočasné pravidlá

header

Vrátiť

This will remove all temporary rules

Potvrdiť

This will persist temporary rules

Upraviť

Will enable manual-edit mode (textarea)

Uložiť

Will save manually-edited content and exit manual-edit mode

Zahodiť

Will discard manually-edited content and exit manual-edit mode

Importovať zo súboru...

Exportovať zo súboru

ublock-moje-dynamické-pravidlá_{{datetime}}.txt

default file name to use

Zoznam vašich dynamických filtrovacích pravidiel.

English: List of your dynamic filtering rules.

Syntax pravidla: zdroj cieľ typ akcia (úplná dokumentácia).

English: dynamic rule syntax and full documentation.

Zoradenie:

English: label for sort option.

Typ pravidla

English: a sort option for list of rules.

Zdroj

Doména

Zoznam hostiteľov, pre ktoré webové stránky bude uBlock Origin zakázaný. Jedna položka na riadok. Neplatní hostitelia budú ignorovaní a zakomentovaní.

A concise description of the 'Trusted sites' pane.

Importovať a pripojiť

English: Import and append

Exportovať

English: Export

ublock-moja-biela-listina_{{datetime}}.txt

The default filename to use for import/export purpose

Použiť zmeny

English: Apply changes

Typ

English: Type

Doména

English: Domain

URL

English: URL

Filter

English: Filter

Všetky

Appears in the logger's tab selector

Za oponou

Pretty name for behind-the-scene network requests

Aktívna karta

Appears in the logger's tab selector

Obnoviť obsah karty

Tooltip for the reload button in the logger page

Prepnúť DOM inšpektor

Tooltip for the DOM inspector button in the logger page

Prepnúť na vyskakovací panel

Tooltip for the popup panel button in the logger page

uBlock Origin wiki: Zaznamenávač

Tooltip for the top-right info label in the logger page

Vyčistiť zaznamenávač

Tooltip for the eraser in the logger page; used to blank the content of the logger

Pozastaviť zaznamenávač (vymazať všetky prichádzajúce dáta)

Tooltip for the pause button in the logger page

Pokračovať v zaznamenávaní

Tooltip for the play button in the logger page

Prepnúť filtrovanie zaznamenávača

Tooltip for the row filterer button in the logger page

filtrovať obsah zaznamenávača

Placeholder string for logger output filtering input field

Možnosti filtrovania zaznamenávača

Tooltip for the button to bring up logger output filtering options

Nie

A keyword in the built-in row filtering expression

eventful

A keyword in the built-in row filtering expression: all items corresponding to uBO doing something (blocked, allowed, redirected, etc.)

blokované

povolené

zmenené

Z prvej strany

Z tretej strany

Podrobnosti

Small header to identify the 'Details' pane for a specific logger entry

Filter

Label to identify a filter field

Zoznam filtrov

Label to identify a filter list field

Pravidlo

Label to identify a rule field

Kontext

Label to identify a context field (typically a hostname)

Koreňový kontext

Label to identify a root context field (typically a hostname)

Partnerská strana

Label to identify a field providing partyness information

Typ

Label to identify the type of an entry

URL

Label to identify the URL of an entry

Dynamické filtrovanie URL

Small header to identify the dynamic URL filtering section

Kontext:

Label for the context selector

Typ:

Label for the type selector

Statické filtrovanie

Small header to identify the static filtering section

{{action}} sieťové požiadavky {{type}} {{br}}, ktorých URL adresa sa zhoduje s {{url}} {{br}}a pochádza {{origin}},{{br}}{{importance}} zodpovedajúci výnimkový filter.

Used in the static filtering wizard

Zablokovať

Used in the static filtering wizard

Povoliť

Used in the static filtering wizard

typu “{{type}}”

Used in the static filtering wizard

akéhokoľvek typu

Used in the static filtering wizard

z “{{origin}}”

Used in the static filtering wizard

z odkiaľkoľvek

Used in the static filtering wizard

pokiaľ neexistuje

Used in the static filtering wizard

aj keď existuje

Used in the static filtering wizard

Statický filter <code>{{filter}}</code> bol nájdený v:

Below this sentence, the filter list(s) in which the filter was found

Statický filter <code>{{filter}}</code> sa nepodarilo nájsť v žiadnom momentálne povolenom zozname filtrov

Message to show when a filter cannot be found in any filter lists

Záznamy v zaznamenávači, ktoré nespĺňajú všetky 3 podmienky uvedené nižšie budú automatické zamietnuté:

Logger setting: A sentence to describe the purpose of the settings below

Ponechať záznamy za posledných {{input}} minút

A logger setting

Ponechať načítaných aspoň {{input}} strán na kartu

A logger setting

Ponechať načítaných aspoň {{input}} položiek na kartu

A logger setting

Pre každú položku zobraziť {{input}} riadky vo vertikálnom rozšírenom režime

A logger setting

Skryť stĺpce:

Logger settings: a sentence to describe the purpose of the checkboxes below

{{input}} Čas

A label for the time column

{{input}} Filter/pravidlo

A label for the filter or rule column

{{input}} Kontext

A label for the context column

{{input}} Zdroj požiadavky

A label for the partyness column

Zoznam

Label for radio-button to pick export format

Tabuľka

Neformátované

Label for radio-button to pick export text format

Formátované

Otvoriť

Text for button which open an external webpage in Support pane

Vytvoriť nové hlásenie

Vyhľadať podobné hlásenia

A clickable link in the filter issue reporter section

Dokumentácia

Header of 'Documentation' section in Support pane

Prečítajte si dokumentáciu na uBlock/wiki a dozviete sa o všetkých funkciách uBlock Origin.

First paragraph of 'Documentation' section in Support pane

Otázky a podpora

Header of 'Questions and support' section in Support pane

Odpovede na otázky a iné druhy podpory pomoci sa poskytujú na subreddite <code>/r/uBlockOrigin</code>.

First paragraph of 'Questions and support' section in Support pane

Problémy s filtrom/webová stránka je nefunkčná

Header of 'Filter issues' section in Support pane

Nahlásenie problémov s filtrom s konkrétnymi webovými stránkami na uBlockOrigin/uAssets issue tracker. Vyžaduje sa GitHub účet.

First paragraph of 'Filter issues' section in Support pane

<b>Dôležité:</b> Vyhnite sa používaniu iných podobne zameraných blokátorov spolu s uBlock Origin, pretože to môže spôsobiť problémy s filtrovaním na konkrétnych webových stránkach.

Second paragraph of 'Filter issues' section in Support pane

Tipy: Uistite sa, že je váš zoznam filtrov aktuálny. Záznamenávač je primárnym nástrojom na diagnostiku problémov súvisiacich s filtrami.

Third paragraph of 'Filter issues' section in Support pane

Nahlásiť chybu

Header of 'Bug report' section in Support pane

Nahlásenie problémov so samotným uBlock Origin na uBlockOrigin/uBlock-issue issue tracker. Vyžaduje sa GitHub účet.

First paragraph of 'Bug report' section in Support pane

Informácie o riešení problémov

Header of 'Troubleshooting Information' section in Support pane

Nasledujú technické informácie, ktoré môžu byť užitočné, keď sa vám dobrovoľníci pokúšajú pomôcť vyriešiť problém.

First paragraph of 'Troubleshooting Information' section in Support pane

<b>Dôležité:</b> Potenciálne súkromné alebo citlivé informácie sú štandardne upravované. Upravené informácie môžu sťažiť riešenie problému.

Second paragraph of 'Troubleshooting Information' section in Support pane

Nahlásiť problém s filtrom

Header of 'Report a filter issue' section in Support pane

Aby ste dobrovoľníkov nezaťažovali duplicitnými hláseniami, overte si, či už problém nebol nahlásený.

A paragraph in the filter issue reporter section

Adresa webovej stránky:

Label for the URL of the page

Webová stránka…

Label for widget to select type of issue

-- Vyberte položku --

An entry in the widget used to select the type of issue

Zobrazuje reklamy alebo zvyšky reklám

Je prekrytá alebo má iné nedostatky

Deteguje uBlock Origin

Má problémy súvisiace so súkromím

Je rozbitá, keď je povolený uBlock Origin

Otvára nechcené karty alebo okná

Označiť webstránku ako “NSFW” (<a href="https://wikipedia.org/wiki/Not_safe_for_work">Nie je bezpečné pre prácu”)

A checkbox to use for NSFW sites

Upravovať

Text for 'Redact' button

Neupravovať

Text for 'Unredact' button

Zásady ochrany osobných údajov

Link to privacy policy on GitHub (English)

Zoznam zmien

Zdrojový kód (GPLv3)

English: Source code (GPLv3)

Prispievatelia

English: Contributors

Zdrojový kód

Link text to source code repo

Preklady

Link text to translations repo

Zoznam filtrov

Link text to uBO's own filter lists repo

Externé závislosti (kompatibilné s GPLv3):

Shown in the About pane

Vlastné zoznamy filtrov uBO sú voľne dostupné na týchto stránkach CDN

Shown in the About pane

Keď bude potrebné aktualizovať zoznam filtrov, použije sa náhodne vybraná sieť CDN

Shown in the About pane

Zálohovať do súboru

Text for button to create a backup of all settings

English: my-ublock-backup_{{datetime}}.txt

Obnoviť zo súboru...

English: Restore from file...

Obnoviť na predvolené nastavenia...

English: Reset to default settings...

Všetky vaše nastavenia budú prepísané pomocou dáta zálohovaných dňa {{time}} a uBlock sa reštartne.

Prepísať všetky existujúce nastavenia pomocou zálohovaných dát?

Message asking user to confirm restore

Dáta sa nepodarilo načítať alebo sú neplatné

Message to display when an error occurred during restore

Všetky vaše nastavenia budú odstránené a uBlock sa reštartne.

Obnoviť uBlock na predvolené nastavenia?

Message asking user to confirm reset

Chyba siete: {{msg}}

English: Network error: {{msg}}

uBlock₀: Pridať nasledujúcu URL do zoznamu vlastných filtrov?

Názov: "{{title}}"
URL: {{url}}

No longer used

Pridať

For the button used to subscribe to a filter list

pred minútou

English: a minute ago

pred {{value}} minútami

English: {{value}} minutes ago

pred hodinou

English: an hour ago

pred {{value}} hodinami

English: {{value}} hours ago

pred dňom

English: a day ago

pred {{value}} dňami

English: {{value}} days ago

Zobraziť ovládací panel

Firefox/Fennec-specific: Show Dashboard

Zobraziť Zaznamenávač

Firefox/Fennec-specific: Show Logger

vypnutý

Firefox-specific: appears as 'uBlock₀ (off)'

uBlock Origin zabránil načítaniu nasledujúcej stránky:

Used in the strict-blocking page

Kvôli nasledujúcemu filtru

Used in the strict-blocking page

bez parametrov

label to be used for the parameter-less URL: https://cloud.githubusercontent.com/assets/585534/9832014/bfb1b8f0-593b-11e5-8a27-fba472a5529a.png

Nájdený v:

English: List of filter list names follows

Naspäť

English: Go back

Zatvoriť toto okno

English: Close this window

Zakázať prísne blokovanie pre {{hostname}}

English: Disable strict blocking for {{hostname}} ...

Dočasne

English: Temporarily

Natrvalo

English: Permanently

Exportovať do cloudového úložiska

tooltip

Importovať z cloudového úložiska

tooltip

Importovať z cloudového úložiska a zlúčiť so súčasnými nastaveniami

tooltip

Názov tohto zariadenia:

used as a prompt for the user to provide a custom device name

Upozornenie! Zmenu pokročilých nastavení vykonávate na vlastné nebezpečenstvo.

A warning to users at the top of 'Advanced settings' page

Poslať

for generic 'Submit' buttons

Použiť zmeny

for generic 'Apply changes' buttons

Vrátiť

for generic 'Revert' buttons

bajtov

Zablokovať prvok v ráme…

An entry in the browser's contextual menu

Pridať zoznam filtrov…

Dočasne povoliť veľké multimediálne prvky

A context menu entry, present when large media elements have been blocked on the current site

Zadajte klávesovú skratku

Placeholder string for input field used to capture a keyboard shortcut

Prepnúť zámok posúvania

Tooltip for the button used to lock scrolling between the views in the 'My rules' pane

Kopírovať do schránky

Label for buttons used to copy something to the clipboard

Označiť všetko

Label for buttons used to select all text in editor

Prepnúť profil blokovania

Label for keyboard shortcut used to toggle blocking profile

Zmierniť režim blokovania

Label for keyboard shortcut used to relax blocking mode (meant to replace 'Toggle blocking profile')

Využité miesto: {{value}} {{unit}}

In Setting pane, renders as (example): Storage used: 13.2 MB

KB

short for 'kilobytes'

MB

short for 'megabytes'

GB

short for 'gigabytes'

Kliknite pre načítanie

Message used in frame placeholders

This entry must be the last one

so we dont need to deal with comma for last entry