././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5230262 nbgitpuller-1.0.2/0000755000175100001710000000000000000000000014641 5ustar00runnerdocker00000000000000././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/CHANGELOG.md0000644000175100001710000003563600000000000016467 0ustar00runnerdocker00000000000000## 1.0 ### 1.0.2 - 2021-09-03 A release to fix an issue that stopped us from publishing nbgitpuller on conda-forge. #### Maintenance and upkeep improvements - Fix jupyter-packaging reference, use - instead of _ [#219](https://github.com/jupyterhub/nbgitpuller/pull/219) ([@consideRatio](https://github.com/consideRatio)) ### 1.0.1 - 2021-09-02 This release fixes a failure to install from a source distribution of the package without having `node` and `npm` installed. #### Maintenance and upkeep improvements - Remove six from dev-requirements.txt [#213](https://github.com/jupyterhub/nbgitpuller/pull/213) ([@consideRatio](https://github.com/consideRatio)) - Slim package.json to avoid fields relevant to npm publication [#212](https://github.com/jupyterhub/nbgitpuller/pull/212) ([@consideRatio](https://github.com/consideRatio)) - Use jupyter-packaging for npm build [#211](https://github.com/jupyterhub/nbgitpuller/pull/211) ([@manics](https://github.com/manics)) #### Contributors to this release ([GitHub contributors page for this release](https://github.com/jupyterhub/nbgitpuller/graphs/contributors?from=2021-09-01&to=2021-09-02&type=c)) [@consideRatio](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3AconsideRatio+updated%3A2021-09-01..2021-09-02&type=Issues) | [@manics](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Amanics+updated%3A2021-09-01..2021-09-02&type=Issues) ### 1.0.0 - 2021-09-01 This is not a breaking release, we have just decided to let this be 1.0.0 to better communicate changes via the version number in future releases. #### Enhancements made - Support use with jupyter_server by decoupling notebook dependencies [#193](https://github.com/jupyterhub/nbgitpuller/pull/193) ([@GeorgianaElena](https://github.com/GeorgianaElena)) #### Bugs fixed - Use addon instead of term when calling fit and import xterm css [#197](https://github.com/jupyterhub/nbgitpuller/pull/197) ([@GeorgianaElena](https://github.com/GeorgianaElena)) #### Maintenance and upkeep improvements - Rename nbgitpuller repo's master branch to main [#189](https://github.com/jupyterhub/nbgitpuller/pull/189) ([@consideRatio](https://github.com/consideRatio)) #### Documentation improvements - Update contributing guide to use `git-pull` [#202](https://github.com/jupyterhub/nbgitpuller/pull/202) ([@fperez](https://github.com/fperez)) #### Contributors to this release ([GitHub contributors page for this release](https://github.com/jupyterhub/nbgitpuller/graphs/contributors?from=2021-06-24&to=2021-08-31&type=c)) [@choldgraf](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Acholdgraf+updated%3A2021-06-24..2021-08-31&type=Issues) | [@consideRatio](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3AconsideRatio+updated%3A2021-06-24..2021-08-31&type=Issues) | [@fmaussion](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Afmaussion+updated%3A2021-06-24..2021-08-31&type=Issues) | [@fperez](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Afperez+updated%3A2021-06-24..2021-08-31&type=Issues) | [@GeorgianaElena](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3AGeorgianaElena+updated%3A2021-06-24..2021-08-31&type=Issues) | [@manics](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Amanics+updated%3A2021-06-24..2021-08-31&type=Issues) | [@nibheis](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Anibheis+updated%3A2021-06-24..2021-08-31&type=Issues) | [@TimoRoth](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3ATimoRoth+updated%3A2021-06-24..2021-08-31&type=Issues) | [@welcome](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Awelcome+updated%3A2021-06-24..2021-08-31&type=Issues) | [@yuvipanda](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Ayuvipanda+updated%3A2021-06-24..2021-08-31&type=Issues) ## 0.10 ### 0.10.2 - 2021-08-25 This is a critical security release, please upgrade to this and see [GHSA-mq5p-2mcr-m52j](https://github.com/jupyterhub/nbgitpuller/security/advisories/GHSA-mq5p-2mcr-m52j) more information. ### 0.10.1 - 2021-06-24 #### Bugs fixed - Added branch name back to command-line usage [#185](https://github.com/jupyterhub/nbgitpuller/pull/185) ([@sean-morris](https://github.com/sean-morris)) #### Documentation improvements - Provide cleaner feedback for lint vs test failures [#181](https://github.com/jupyterhub/nbgitpuller/pull/181) ([@yuvipanda](https://github.com/yuvipanda)) #### Continuous integration - Fix CI failures by disabling pip cache [#188](https://github.com/jupyterhub/nbgitpuller/pull/188) ([@consideRatio](https://github.com/consideRatio)) #### Contributors to this release ([GitHub contributors page for this release](https://github.com/jupyterhub/nbgitpuller/graphs/contributors?from=2021-06-09&to=2021-06-24&type=c)) [@consideRatio](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3AconsideRatio+updated%3A2021-06-09..2021-06-24&type=Issues) | [@manics](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Amanics+updated%3A2021-06-09..2021-06-24&type=Issues) | [@sean-morris](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Asean-morris+updated%3A2021-06-09..2021-06-24&type=Issues) | [@yuvipanda](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Ayuvipanda+updated%3A2021-06-09..2021-06-24&type=Issues) ### 0.10.0 - 2021-06-09 #### Enhancements made - UI: Branch input placeholder no longer suggests master branch [#180](https://github.com/jupyterhub/nbgitpuller/pull/180) ([@sean-morris](https://github.com/sean-morris)) - Automatically detect default branch name [#179](https://github.com/jupyterhub/nbgitpuller/pull/179) ([@sean-morris](https://github.com/sean-morris)) - Tell users about `main` vs `master` branches [#170](https://github.com/jupyterhub/nbgitpuller/pull/170) ([@yuvipanda](https://github.com/yuvipanda)) - Support generating shiny links [#165](https://github.com/jupyterhub/nbgitpuller/pull/165) ([@yuvipanda](https://github.com/yuvipanda)) #### Bugs fixed - Handle lack of trailing slashes in hub URLs [#173](https://github.com/jupyterhub/nbgitpuller/pull/173) ([@yuvipanda](https://github.com/yuvipanda)) - Respect path component of JupyterHub url [#172](https://github.com/jupyterhub/nbgitpuller/pull/172) ([@yuvipanda](https://github.com/yuvipanda)) - Parse ssh git URLs properly [#163](https://github.com/jupyterhub/nbgitpuller/pull/163) ([@yuvipanda](https://github.com/yuvipanda)) - Fix failure to restore deleted files (use raw output of git ls-files to avoid quoting unicode) [#156](https://github.com/jupyterhub/nbgitpuller/pull/156) ([@manics](https://github.com/manics)) - Compare current branch to target - don't assume already on target branch locally [#141](https://github.com/jupyterhub/nbgitpuller/pull/141) ([@danlester](https://github.com/danlester)) #### Documentation improvements - Document restarting notebook process to see changes [#178](https://github.com/jupyterhub/nbgitpuller/pull/178) ([@yuvipanda](https://github.com/yuvipanda)) - docs: update README.md badges [#175](https://github.com/jupyterhub/nbgitpuller/pull/175) ([@consideRatio](https://github.com/consideRatio)) - Add best practices recommendation documentation [#169](https://github.com/jupyterhub/nbgitpuller/pull/169) ([@yuvipanda](https://github.com/yuvipanda)) - Document how to do local development [#162](https://github.com/jupyterhub/nbgitpuller/pull/162) ([@yuvipanda](https://github.com/yuvipanda)) - Add badges to README.md [#150](https://github.com/jupyterhub/nbgitpuller/pull/150) ([@consideRatio](https://github.com/consideRatio)) #### Continuous Integration - CI: Replace Travis with GitHub workflow [#161](https://github.com/jupyterhub/nbgitpuller/pull/161) ([@manics](https://github.com/manics)) - CI: stop triggering CircleCI on automated pushes to gh-pages [#151](https://github.com/jupyterhub/nbgitpuller/pull/151) ([@consideRatio](https://github.com/consideRatio)) #### Contributors to this release ([GitHub contributors page for this release](https://github.com/jupyterhub/nbgitpuller/graphs/contributors?from=2020-08-01&to=2021-06-09&type=c)) [@albertmichaelj](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Aalbertmichaelj+updated%3A2020-08-01..2021-06-09&type=Issues) | [@choldgraf](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Acholdgraf+updated%3A2020-08-01..2021-06-09&type=Issues) | [@consideRatio](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3AconsideRatio+updated%3A2020-08-01..2021-06-09&type=Issues) | [@danlester](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Adanlester+updated%3A2020-08-01..2021-06-09&type=Issues) | [@giumas](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Agiumas+updated%3A2020-08-01..2021-06-09&type=Issues) | [@manics](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Amanics+updated%3A2020-08-01..2021-06-09&type=Issues) | [@minrk](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Aminrk+updated%3A2020-08-01..2021-06-09&type=Issues) | [@ryanlovett](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Aryanlovett+updated%3A2020-08-01..2021-06-09&type=Issues) | [@SaladRaider](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3ASaladRaider+updated%3A2020-08-01..2021-06-09&type=Issues) | [@samuelmanzer](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Asamuelmanzer+updated%3A2020-08-01..2021-06-09&type=Issues) | [@sean-morris](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Asean-morris+updated%3A2020-08-01..2021-06-09&type=Issues) | [@ttimbers](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Attimbers+updated%3A2020-08-01..2021-06-09&type=Issues) | [@welcome](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Awelcome+updated%3A2020-08-01..2021-06-09&type=Issues) | [@yuvipanda](https://github.com/search?q=repo%3Ajupyterhub%2Fnbgitpuller+involves%3Ayuvipanda+updated%3A2020-08-01..2021-06-09&type=Issues) ## 0.9 ### 0.9.0 - 2020-09-1 - Allow destination to be configured ([#42](https://github.com/jupyterhub/nbgitpuller/pull/42)) - Made the checkout from the reset_deleted_files to use the origin. ([#111](https://github.com/jupyterhub/nbgitpuller/pull/111)) - Update version. ([#112](https://github.com/jupyterhub/nbgitpuller/pull/112)) - Update index.rst ([#113](https://github.com/jupyterhub/nbgitpuller/pull/113)) - Use shallow clones by default ([#117](https://github.com/jupyterhub/nbgitpuller/pull/117)) - updating theme ([#126](https://github.com/jupyterhub/nbgitpuller/pull/126)) - Update ipynb with newer query parameters and toggles ([#127](https://github.com/jupyterhub/nbgitpuller/pull/127)) - Add a mybinder.org tab to the link builder ([#129](https://github.com/jupyterhub/nbgitpuller/pull/129)) - tab activation on link generator ([#132](https://github.com/jupyterhub/nbgitpuller/pull/132)) - fixing bug ([#134](https://github.com/jupyterhub/nbgitpuller/pull/134)) - Fix typo from ipynb link generator external tool reference ([#136](https://github.com/jupyterhub/nbgitpuller/pull/136)) - Use the correct branch for contentRepo ([#138](https://github.com/jupyterhub/nbgitpuller/pull/138)) - Fix file paths or application paths ([#140](https://github.com/jupyterhub/nbgitpuller/pull/140)) - Make the environment repo branch required for binder ([#143](https://github.com/jupyterhub/nbgitpuller/pull/143)) - Travis pypi deployment, README fixes ([#145](https://github.com/jupyterhub/nbgitpuller/pull/145)) - Replace data-8 with jupyterhub ([#146](https://github.com/jupyterhub/nbgitpuller/pull/146)) - CI: fix broken test assertions following --depth 1 by default ([#147](https://github.com/jupyterhub/nbgitpuller/pull/147)) - CI: ensure tox run's flake8 as well ([#148](https://github.com/jupyterhub/nbgitpuller/pull/148)) ## 0.8 ### 0.8.0 2019-11-23 - Link generator: init application type from query params ([#107](https://github.com/jupyterhub/nbgitpuller/pull/107)) - Made the checkout from the reset_deleted_files to use the origin. ([#111](https://github.com/jupyterhub/nbgitpuller/pull/111)) ## 0.7 ### 0.7.2 - 2019-10-3 - Bump version number ([#103](https://github.com/jupyterhub/nbgitpuller/pull/103)) - Set authorship info on each commit, rather than repo-wide ([#104](https://github.com/jupyterhub/nbgitpuller/pull/104)) - Bump version number ([#105](https://github.com/jupyterhub/nbgitpuller/pull/105)) ### 0.7.1 2019-10-3 - Update version to 0.7.0. ([#100](https://github.com/jupyterhub/nbgitpuller/pull/100)) - Fix legacy links with empty path ([#102](https://github.com/jupyterhub/nbgitpuller/pull/102)) - Bump version number ([#103](https://github.com/jupyterhub/nbgitpuller/pull/103)) ### 0.7.0 2019-07-31 - adding a link generator binder ([#49](https://github.com/jupyterhub/nbgitpuller/pull/49)) - Clean up link_generator notebook / app ([#50](https://github.com/jupyterhub/nbgitpuller/pull/50)) - add link to TLJH guide in readme ([#52](https://github.com/jupyterhub/nbgitpuller/pull/52)) - updating link sanitizing ([#54](https://github.com/jupyterhub/nbgitpuller/pull/54)) - adds link to a basic video instruction ([#56](https://github.com/jupyterhub/nbgitpuller/pull/56)) - Add new link generator instructions ([#62](https://github.com/jupyterhub/nbgitpuller/pull/62)) - adding new nbgitpuller link gen app ([#63](https://github.com/jupyterhub/nbgitpuller/pull/63)) - Implement depth/shallow-clone support ([#67](https://github.com/jupyterhub/nbgitpuller/pull/67)) - Made repo_dir an absolute path based on the server_root_dir. ([#71](https://github.com/jupyterhub/nbgitpuller/pull/71)) - Serve gh pages from docs/ not gh-pages ([#73](https://github.com/jupyterhub/nbgitpuller/pull/73)) - Pass nbapp along to GitPuller so it can read from our configuration ([#75](https://github.com/jupyterhub/nbgitpuller/pull/75)) - Rework nbgitpuller link generator ([#76](https://github.com/jupyterhub/nbgitpuller/pull/76)) - Generate URLs that can be launched from canvas ([#78](https://github.com/jupyterhub/nbgitpuller/pull/78)) - Don't require including cloned dir name in path to open ([#79](https://github.com/jupyterhub/nbgitpuller/pull/79)) - adding documentation ([#81](https://github.com/jupyterhub/nbgitpuller/pull/81)) - circle config to push docs ([#82](https://github.com/jupyterhub/nbgitpuller/pull/82)) - documentation clarification ([#88](https://github.com/jupyterhub/nbgitpuller/pull/88)) - Redo documentation ([#92](https://github.com/jupyterhub/nbgitpuller/pull/92)) - Allow git@example.com:repo links ([#97](https://github.com/jupyterhub/nbgitpuller/pull/97)) ## 0.6 ### 0.6.1 2018-07-19 - Install Jupyter notebook extension by default, Add missing nbgitpuller.json file ### 0.6.0 2018-07-18 - Work with (and require) newer notebook version ([#46](https://github.com/jupyterhub/nbgitpuller/pull/46)) - Update README.md ([#48](https://github.com/jupyterhub/nbgitpuller/pull/48)) ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/LICENSE0000644000175100001710000000276400000000000015657 0ustar00runnerdocker00000000000000BSD 3-Clause License Copyright (c) 2017, YuviPanda, Peter Veerman All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/MANIFEST.in0000644000175100001710000000022500000000000016376 0ustar00runnerdocker00000000000000include *.md include LICENSE include package.json include setup.cfg recursive-include nbgitpuller/static * recursive-include nbgitpuller/templates * ././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5230262 nbgitpuller-1.0.2/PKG-INFO0000644000175100001710000000423100000000000015736 0ustar00runnerdocker00000000000000Metadata-Version: 2.1 Name: nbgitpuller Version: 1.0.2 Summary: Notebook Extension to do one-way synchronization of git repositories Home-page: https://github.com/jupyterhub/nbgitpuller Author: Peter Veerman, YuviPanda Author-email: peterkangveerman@gmail.com License: 3-clause BSD Platform: any Classifier: Development Status :: 4 - Beta Classifier: License :: OSI Approved :: BSD License Classifier: Operating System :: POSIX Classifier: Operating System :: MacOS Classifier: Operating System :: Unix Classifier: Programming Language :: Python :: 3 Classifier: Topic :: Software Development :: Libraries :: Python Modules Description-Content-Type: text/markdown License-File: LICENSE # [nbgitpuller](https://github.com/jupyterhub/nbgitpuller) [![GitHub Workflow Status - Test](https://img.shields.io/github/workflow/status/jupyterhub/nbgitpuller/Tests?logo=github&label=tests)](https://github.com/jupyterhub/nbgitpuller/actions) [![CircleCI build status](https://img.shields.io/circleci/build/github/jupyterhub/nbgitpuller?logo=circleci&label=docs)](https://circleci.com/gh/jupyterhub/nbgitpuller) [![](https://img.shields.io/pypi/v/nbgitpuller.svg?logo=pypi)](https://pypi.python.org/pypi/nbgitpuller) [![GitHub](https://img.shields.io/badge/issue_tracking-github-blue?logo=github)](https://github.com/jupyterhub/nbgitpuller/issues) [![Discourse](https://img.shields.io/badge/help_forum-discourse-blue?logo=discourse)](https://discourse.jupyter.org/c/jupyterhub) [![Gitter](https://img.shields.io/badge/social_chat-gitter-blue?logo=gitter)](https://gitter.im/jupyterhub/jupyterhub) `nbgitpuller` lets you distribute content in a git repository to your students by having them click a simple link. [Automatic merging](https://jupyterhub.github.io/nbgitpuller/topic/automatic-merging.html) ensures that your students are never exposed to `git` directly. It is primarily used with a JupyterHub, but can also work on students' local computers. See [the documentation](https://jupyterhub.github.io/nbgitpuller) for more information. ## Installation ```shell pip install nbgitpuller ``` ## Example ![](https://raw.githubusercontent.com/jupyterhub/nbgitpuller/v0.8.0/docs/_static/nbpuller.gif) ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/README.md0000644000175100001710000000275000000000000016124 0ustar00runnerdocker00000000000000# [nbgitpuller](https://github.com/jupyterhub/nbgitpuller) [![GitHub Workflow Status - Test](https://img.shields.io/github/workflow/status/jupyterhub/nbgitpuller/Tests?logo=github&label=tests)](https://github.com/jupyterhub/nbgitpuller/actions) [![CircleCI build status](https://img.shields.io/circleci/build/github/jupyterhub/nbgitpuller?logo=circleci&label=docs)](https://circleci.com/gh/jupyterhub/nbgitpuller) [![](https://img.shields.io/pypi/v/nbgitpuller.svg?logo=pypi)](https://pypi.python.org/pypi/nbgitpuller) [![GitHub](https://img.shields.io/badge/issue_tracking-github-blue?logo=github)](https://github.com/jupyterhub/nbgitpuller/issues) [![Discourse](https://img.shields.io/badge/help_forum-discourse-blue?logo=discourse)](https://discourse.jupyter.org/c/jupyterhub) [![Gitter](https://img.shields.io/badge/social_chat-gitter-blue?logo=gitter)](https://gitter.im/jupyterhub/jupyterhub) `nbgitpuller` lets you distribute content in a git repository to your students by having them click a simple link. [Automatic merging](https://jupyterhub.github.io/nbgitpuller/topic/automatic-merging.html) ensures that your students are never exposed to `git` directly. It is primarily used with a JupyterHub, but can also work on students' local computers. See [the documentation](https://jupyterhub.github.io/nbgitpuller) for more information. ## Installation ```shell pip install nbgitpuller ``` ## Example ![](https://raw.githubusercontent.com/jupyterhub/nbgitpuller/v0.8.0/docs/_static/nbpuller.gif) ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/RELEASE.md0000644000175100001710000000401200000000000016240 0ustar00runnerdocker00000000000000# How to make a release `nbgitpuller` is a package available on [PyPI](https://pypi.org/project/nbgitpuller/) and [conda-forge](https://anaconda.org/conda-forge/nbgitpuller). These are instructions on how to make a release on PyPI. The PyPI release is done automatically by TravisCI when a tag is pushed. ## Steps to make a release 1. Checkout main and make sure it is up to date. ```shell ORIGIN=${ORIGIN:-origin} # set to the canonical remote, e.g. 'upstream' if 'origin' is not the official repo git checkout main git fetch $ORIGIN main git reset --hard $ORIGIN/main # WARNING! This next command deletes any untracked files in the repo git clean -xfd ``` 1. Set the `__version__` variable in [`nbgitpuller/version.py`](nbgitpuller/version.py) and make a commit. ```shell git add nbgitpuller/version.py VERSION=... # e.g. 1.2.3 git commit -m "release $VERSION" ``` 1. Reset the `__version__` variable in [`nbgitpuller/version.py`](nbgitpuller/version.py) to an incremented patch version with a `dev` element, then make a commit. ```shell git add nbgitpuller/version.py git commit -m "back to dev" ``` 1. Push your two commits to main. ```shell # first push commits without a tags to ensure the # commits comes through, because a tag can otherwise # be pushed all alone without company of rejected # commits, and we want have our tagged release coupled # with a specific commit in main git push $ORIGIN main ``` 1. Create a git tag for the pushed release commit and push it. ```shell git tag -a $VERSION -m $VERSION HEAD~1 # then verify you tagged the right commit git log # then push it git push $ORIGIN refs/tags/$VERSION ``` 1. Following the release to PyPI, an automated PR should arrive to [conda-forge/nbgitpuller-feedstock](https://github.com/conda-forge/nbgitpuller-feedstock), check for the tests to succeed on this PR and then merge it to successfully update the package for `conda` on the `conda-forge` channel. ././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5150263 nbgitpuller-1.0.2/nbgitpuller/0000755000175100001710000000000000000000000017170 5ustar00runnerdocker00000000000000././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/nbgitpuller/__init__.py0000644000175100001710000000216100000000000021301 0ustar00runnerdocker00000000000000from .version import __version__ # noqa from .handlers import SyncHandler, UIHandler, LegacyInteractRedirectHandler, LegacyGitSyncRedirectHandler from .pull import GitPuller # noqa from notebook.utils import url_path_join from tornado.web import StaticFileHandler import os def _jupyter_server_extension_paths(): return [{ 'module': 'nbgitpuller', }] def load_jupyter_server_extension(nbapp): web_app = nbapp.web_app base_url = url_path_join(web_app.settings['base_url'], 'git-pull') handlers = [ (url_path_join(base_url, 'api'), SyncHandler), (base_url, UIHandler), (url_path_join(web_app.settings['base_url'], 'git-sync'), LegacyGitSyncRedirectHandler), (url_path_join(web_app.settings['base_url'], 'interact'), LegacyInteractRedirectHandler), ( url_path_join(base_url, 'static', '(.*)'), StaticFileHandler, {'path': os.path.join(os.path.dirname(__file__), 'static')} ) ] web_app.settings['nbapp'] = nbapp web_app.add_handlers('.*', handlers) _load_jupyter_server_extension = load_jupyter_server_extension ././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5110261 nbgitpuller-1.0.2/nbgitpuller/etc/0000755000175100001710000000000000000000000017743 5ustar00runnerdocker00000000000000././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5190263 nbgitpuller-1.0.2/nbgitpuller/etc/jupyter_notebook_config.d/0000755000175100001710000000000000000000000025114 5ustar00runnerdocker00000000000000././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/nbgitpuller/etc/jupyter_notebook_config.d/nbgitpuller.json0000644000175100001710000000013100000000000030331 0ustar00runnerdocker00000000000000{ "NotebookApp": { "nbserver_extensions": { "nbgitpuller": true } } } ././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5190263 nbgitpuller-1.0.2/nbgitpuller/etc/jupyter_server_config.d/0000755000175100001710000000000000000000000024602 5ustar00runnerdocker00000000000000././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/nbgitpuller/etc/jupyter_server_config.d/nbgitpuller.json0000644000175100001710000000012700000000000030024 0ustar00runnerdocker00000000000000{ "ServerApp": { "jpserver_extensions": { "nbgitpuller": true } } } ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/nbgitpuller/handlers.py0000644000175100001710000001644100000000000021350 0ustar00runnerdocker00000000000000from tornado import gen, web, locks import traceback import urllib.parse from notebook.base.handlers import IPythonHandler import threading import json import os from queue import Queue, Empty import jinja2 from .pull import GitPuller from .version import __version__ class SyncHandler(IPythonHandler): def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) # We use this lock to make sure that only one sync operation # can be happening at a time. Git doesn't like concurrent use! if 'git_lock' not in self.settings: self.settings['git_lock'] = locks.Lock() @property def git_lock(self): return self.settings['git_lock'] @gen.coroutine def emit(self, data): if type(data) is not str: serialized_data = json.dumps(data) if 'output' in data: self.log.info(data['output'].rstrip()) else: serialized_data = data self.log.info(data) self.write('data: {}\n\n'.format(serialized_data)) yield self.flush() @web.authenticated @gen.coroutine def get(self): try: yield self.git_lock.acquire(1) except gen.TimeoutError: self.emit({ 'phase': 'error', 'message': 'Another git operations is currently running, try again in a few minutes' }) return try: repo = self.get_argument('repo') branch = self.get_argument('branch', None) depth = self.get_argument('depth', None) if depth: depth = int(depth) # The default working directory is the directory from which Jupyter # server is launched, which is not the same as the root notebook # directory assuming either --notebook-dir= is used from the # command line or c.NotebookApp.notebook_dir is set in the jupyter # configuration. This line assures that all repos are cloned # relative to server_root_dir/, # so that all repos are always in scope after cloning. Sometimes # server_root_dir will include things like `~` and so the path # must be expanded. repo_parent_dir = os.path.join(os.path.expanduser(self.settings['server_root_dir']), os.getenv('NBGITPULLER_PARENTPATH', '')) repo_dir = os.path.join(repo_parent_dir, self.get_argument('targetpath', repo.split('/')[-1])) # We gonna send out event streams! self.set_header('content-type', 'text/event-stream') self.set_header('cache-control', 'no-cache') gp = GitPuller(repo, repo_dir, branch=branch, depth=depth, parent=self.settings['nbapp']) q = Queue() def pull(): try: for line in gp.pull(): q.put_nowait(line) # Sentinel when we're done q.put_nowait(None) except Exception as e: q.put_nowait(e) raise e self.gp_thread = threading.Thread(target=pull) self.gp_thread.start() while True: try: progress = q.get_nowait() except Empty: yield gen.sleep(0.5) continue if progress is None: break if isinstance(progress, Exception): self.emit({ 'phase': 'error', 'message': str(progress), 'output': '\n'.join([ line.strip() for line in traceback.format_exception( type(progress), progress, progress.__traceback__ ) ]) }) return self.emit({'output': progress, 'phase': 'syncing'}) self.emit({'phase': 'finished'}) except Exception as e: self.emit({ 'phase': 'error', 'message': str(e), 'output': '\n'.join([ line.strip() for line in traceback.format_exception( type(e), e, e.__traceback__ ) ]) }) finally: self.git_lock.release() class UIHandler(IPythonHandler): def initialize(self): super().initialize() # FIXME: Is this really the best way to use jinja2 here? # I can't seem to get the jinja2 env in the base handler to # actually load templates from arbitrary paths ugh. jinja2_env = self.settings['jinja2_env'] jinja2_env.loader = jinja2.ChoiceLoader([ jinja2_env.loader, jinja2.FileSystemLoader( os.path.join(os.path.dirname(__file__), 'templates') ) ]) @web.authenticated @gen.coroutine def get(self): app_env = os.getenv('NBGITPULLER_APP', default='notebook') repo = self.get_argument('repo') branch = self.get_argument('branch', None) depth = self.get_argument('depth', None) urlPath = self.get_argument('urlpath', None) or \ self.get_argument('urlPath', None) subPath = self.get_argument('subpath', None) or \ self.get_argument('subPath', '.') app = self.get_argument('app', app_env) parent_reldir = os.getenv('NBGITPULLER_PARENTPATH', '') targetpath = self.get_argument('targetpath', None) or \ self.get_argument('targetPath', repo.split('/')[-1]) if urlPath: path = urlPath else: path = os.path.join(parent_reldir, targetpath, subPath) if app.lower() == 'lab': path = 'lab/tree/' + path elif path.lower().endswith('.ipynb'): path = 'notebooks/' + path else: path = 'tree/' + path self.write( self.render_template( 'status.html', repo=repo, branch=branch, path=path, depth=depth, targetpath=targetpath, version=__version__ )) self.flush() class LegacyGitSyncRedirectHandler(IPythonHandler): @web.authenticated @gen.coroutine def get(self): new_url = '{base}git-pull?{query}'.format( base=self.base_url, query=self.request.query ) self.redirect(new_url) class LegacyInteractRedirectHandler(IPythonHandler): @web.authenticated @gen.coroutine def get(self): repo = self.get_argument('repo') account = self.get_argument('account', 'data-8') repo_url = 'https://github.com/{account}/{repo}'.format(account=account, repo=repo) query = { 'repo': repo_url, # branch & subPath are optional 'branch': self.get_argument('branch', 'gh-pages'), 'subPath': self.get_argument('path', '.') } new_url = '{base}git-pull?{query}'.format( base=self.base_url, query=urllib.parse.urlencode(query) ) self.redirect(new_url) ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/nbgitpuller/pull.py0000644000175100001710000002751500000000000020530 0ustar00runnerdocker00000000000000import os import subprocess import logging import time import argparse import datetime from traitlets import Integer, default from traitlets.config import Configurable from functools import partial def execute_cmd(cmd, **kwargs): """ Call given command, yielding output line by line """ yield '$ {}\n'.format(' '.join(cmd)) kwargs['stdout'] = subprocess.PIPE kwargs['stderr'] = subprocess.STDOUT proc = subprocess.Popen(cmd, **kwargs) # Capture output for logging. # Each line will be yielded as text. # This should behave the same as .readline(), but splits on `\r` OR `\n`, # not just `\n`. buf = [] def flush(): line = b''.join(buf).decode('utf8', 'replace') buf[:] = [] return line c_last = '' try: for c in iter(partial(proc.stdout.read, 1), b''): if c_last == b'\r' and buf and c != b'\n': yield flush() buf.append(c) if c == b'\n': yield flush() c_last = c finally: ret = proc.wait() if ret != 0: raise subprocess.CalledProcessError(ret, cmd) class GitPuller(Configurable): depth = Integer( config=True, help=""" Depth (ie, commit count) of clone operations. Set this to 0 to make a full depth clone. Defaults to the value of the environment variable NBGITPULLER_DEPTH, or 1 if the the environment variable isn't set. """ ) @default('depth') def _depth_default(self): """This is a workaround for setting the same default directly in the definition of the traitlet above. Without it, the test fails because a change in the environment variable has no impact. I think this is a consequence of the tests not starting with a totally clean environment where the GitPuller class hadn't been loaded already.""" return int(os.environ.get('NBGITPULLER_DEPTH', 1)) def __init__(self, git_url, repo_dir, **kwargs): assert git_url self.git_url = git_url self.branch_name = kwargs.pop("branch") if self.branch_name is None: self.branch_name = self.resolve_default_branch() elif not self.branch_exists(self.branch_name): raise ValueError(f"Branch: {self.branch_name} -- not found in repo: {self.git_url}") self.repo_dir = repo_dir newargs = {k: v for k, v in kwargs.items() if v is not None} super(GitPuller, self).__init__(**newargs) def branch_exists(self, branch): """ This checks to make sure the branch we are told to access exists in the repo """ try: heads = subprocess.run( ["git", "ls-remote", "--heads", "--", self.git_url], capture_output=True, text=True, check=True ) tags = subprocess.run( ["git", "ls-remote", "--tags", "--", self.git_url], capture_output=True, text=True, check=True ) lines = heads.stdout.splitlines() + tags.stdout.splitlines() branches = [] for line in lines: _, ref = line.split() refs, heads, branch_name = ref.split("/", 2) branches.append(branch_name) return branch in branches except subprocess.CalledProcessError: m = f"Problem accessing list of branches and/or tags: {self.git_url}" logging.exception(m) raise ValueError(m) def resolve_default_branch(self): """ This will resolve the default branch of the repo in the case where the branch given does not exist """ try: head_branch = subprocess.run( ["git", "ls-remote", "--symref", "--", self.git_url, "HEAD"], capture_output=True, text=True, check=True ) for line in head_branch.stdout.splitlines(): if line.startswith("ref:"): # line resembles --> ref: refs/heads/main HEAD _, ref, head = line.split() refs, heads, branch_name = ref.split("/", 2) return branch_name raise ValueError(f"default branch not found in {self.git_url}") except subprocess.CalledProcessError: m = f"Problem accessing HEAD branch: {self.git_url}" logging.exception(m) raise ValueError(m) def pull(self): """ Pull selected repo from a remote git repository, while preserving user changes """ if not os.path.exists(self.repo_dir): yield from self.initialize_repo() else: yield from self.update() def initialize_repo(self): """ Clones repository """ logging.info('Repo {} doesn\'t exist. Cloning...'.format(self.repo_dir)) clone_args = ['git', 'clone'] if self.depth and self.depth > 0: clone_args.extend(['--depth', str(self.depth)]) clone_args.extend(['--branch', self.branch_name]) clone_args.extend(["--", self.git_url, self.repo_dir]) yield from execute_cmd(clone_args) logging.info('Repo {} initialized'.format(self.repo_dir)) def reset_deleted_files(self): """ Runs the equivalent of git checkout -- for each file that was deleted. This allows us to delete a file, hit an interact link, then get a clean version of the file again. """ yield from self.ensure_lock() deleted_files = subprocess.check_output([ 'git', 'ls-files', '--deleted', '-z' ], cwd=self.repo_dir).decode().strip().split('\0') for filename in deleted_files: if filename: # Filter out empty lines yield from execute_cmd(['git', 'checkout', 'origin/{}'.format(self.branch_name), '--', filename], cwd=self.repo_dir) def repo_is_dirty(self): """ Return true if repo is dirty """ try: subprocess.check_call(['git', 'diff-files', '--quiet'], cwd=self.repo_dir) # Return code is 0 return False except subprocess.CalledProcessError: return True def update_remotes(self): """ Do a git fetch so our remotes are up to date """ yield from execute_cmd(['git', 'fetch'], cwd=self.repo_dir) def find_upstream_changed(self, kind): """ Return list of files that have been changed upstream belonging to a particular kind of change """ output = subprocess.check_output([ 'git', 'log', '..origin/{}'.format(self.branch_name), '--oneline', '--name-status' ], cwd=self.repo_dir).decode() files = [] for line in output.split('\n'): if line.startswith(kind): files.append(os.path.join(self.repo_dir, line.split('\t', 1)[1])) return files def ensure_lock(self): """ Make sure we have the .git/lock required to do modifications on the repo This must be called before any git commands that modify state. This isn't guaranteed to be atomic, due to the nature of using files for locking. But it's the best we can do right now. """ try: lockpath = os.path.join(self.repo_dir, '.git', 'index.lock') mtime = os.path.getmtime(lockpath) # A lock file does exist # If it's older than 10 minutes, we just assume it is stale and take over # If not, we fail with an explicit error. if time.time() - mtime > 600: yield "Stale .git/index.lock found, attempting to remove" os.remove(lockpath) yield "Stale .git/index.lock removed" else: raise Exception('Recent .git/index.lock found, operation can not proceed. Try again in a few minutes.') except FileNotFoundError: # No lock is held by other processes, we are free to go return def rename_local_untracked(self): """ Rename local untracked files that would require pulls """ # Find what files have been added! new_upstream_files = self.find_upstream_changed('A') for f in new_upstream_files: if os.path.exists(f): # If there's a file extension, put the timestamp before that ts = datetime.datetime.now().strftime('__%Y%m%d%H%M%S') path_head, path_tail = os.path.split(f) path_tail = ts.join(os.path.splitext(path_tail)) new_file_name = os.path.join(path_head, path_tail) os.rename(f, new_file_name) yield 'Renamed {} to {} to avoid conflict with upstream'.format(f, new_file_name) def update(self): """ Do the pulling if necessary """ # Fetch remotes, so we know we're dealing with latest remote yield from self.update_remotes() # Rename local untracked files that might be overwritten by pull yield from self.rename_local_untracked() # Reset local files that have been deleted. We don't actually expect users to # delete something that's present upstream and expect to keep it. This prevents # unnecessary conflicts, and also allows users to click the link again to get # a fresh copy of a file they might have screwed up. yield from self.reset_deleted_files() # If there are local changes, make a commit so we can do merges when pulling # We also allow empty commits. On NFS (at least), sometimes repo_is_dirty returns a false # positive, returning True even when there are no local changes (git diff-files seems to return # bogus output?). While ideally that would not happen, allowing empty commits keeps us # resilient to that issue. # We explicitly set user info of the commits we are making, to keep that separate from # whatever author info is set in system / repo config by the user. We pass '-c' to git # itself (rather than to 'git commit') to temporarily set config variables. This is # better than passing --author, since git treats author separately from committer. if self.repo_is_dirty(): yield from self.ensure_lock() yield from execute_cmd([ 'git', '-c', 'user.email=nbgitpuller@nbgitpuller.link', '-c', 'user.name=nbgitpuller', 'commit', '-am', 'Automatic commit by nbgitpuller', '--allow-empty' ], cwd=self.repo_dir) # Merge master into local! yield from self.ensure_lock() yield from execute_cmd([ 'git', '-c', 'user.email=nbgitpuller@nbgitpuller.link', '-c', 'user.name=nbgitpuller', 'merge', '-Xours', 'origin/{}'.format(self.branch_name) ], cwd=self.repo_dir) def main(): """ Synchronizes a github repository with a local repository. """ logging.basicConfig( format='[%(asctime)s] %(levelname)s -- %(message)s', level=logging.DEBUG) parser = argparse.ArgumentParser(description='Synchronizes a github repository with a local repository.') parser.add_argument('git_url', help='Url of the repo to sync') parser.add_argument('branch_name', default=None, help='Branch of repo to sync', nargs='?') parser.add_argument('repo_dir', default='.', help='Path to clone repo under', nargs='?') args = parser.parse_args() for line in GitPuller( args.git_url, args.repo_dir, branch=args.branch_name if args.branch_name else None ).pull(): print(line) if __name__ == '__main__': main() ././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5110261 nbgitpuller-1.0.2/nbgitpuller/static/0000755000175100001710000000000000000000000020457 5ustar00runnerdocker00000000000000././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5230262 nbgitpuller-1.0.2/nbgitpuller/static/dist/0000755000175100001710000000000000000000000021422 5ustar00runnerdocker00000000000000././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625883.0 nbgitpuller-1.0.2/nbgitpuller/static/dist/bundle.js0000644000175100001710000147553000000000000023250 0ustar00runnerdocker00000000000000/*! For license information please see bundle.js.LICENSE.txt */ (()=>{var e={118:(e,t,r)=>{"use strict";r.d(t,{Z:()=>a});var i=r(799),n=r.n(i),o=r(609),s=r.n(o)()(n());s.push([e.id,'/**\n * Copyright (c) 2014 The xterm.js authors. All rights reserved.\n * Copyright (c) 2012-2013, Christopher Jeffrey (MIT License)\n * https://github.com/chjj/term.js\n * @license MIT\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the "Software"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *\n * Originally forked from (with the author\'s permission):\n * Fabrice Bellard\'s javascript vt100 for jslinux:\n * http://bellard.org/jslinux/\n * Copyright (c) 2011 Fabrice Bellard\n * The original design remains. The terminal itself\n * has been extended to include xterm CSI codes, among\n * other features.\n */\n\n/**\n * Default styles for xterm.js\n */\n\n.xterm {\n position: relative;\n user-select: none;\n -ms-user-select: none;\n -webkit-user-select: none;\n}\n\n.xterm.focus,\n.xterm:focus {\n outline: none;\n}\n\n.xterm .xterm-helpers {\n position: absolute;\n top: 0;\n /**\n * The z-index of the helpers must be higher than the canvases in order for\n * IMEs to appear on top.\n */\n z-index: 5;\n}\n\n.xterm .xterm-helper-textarea {\n padding: 0;\n border: 0;\n margin: 0;\n /* Move textarea out of the screen to the far left, so that the cursor is not visible */\n position: absolute;\n opacity: 0;\n left: -9999em;\n top: 0;\n width: 0;\n height: 0;\n z-index: -5;\n /** Prevent wrapping so the IME appears against the textarea at the correct position */\n white-space: nowrap;\n overflow: hidden;\n resize: none;\n}\n\n.xterm .composition-view {\n /* TODO: Composition position got messed up somewhere */\n background: #000;\n color: #FFF;\n display: none;\n position: absolute;\n white-space: nowrap;\n z-index: 1;\n}\n\n.xterm .composition-view.active {\n display: block;\n}\n\n.xterm .xterm-viewport {\n /* On OS X this is required in order for the scroll bar to appear fully opaque */\n background-color: #000;\n overflow-y: scroll;\n cursor: default;\n position: absolute;\n right: 0;\n left: 0;\n top: 0;\n bottom: 0;\n}\n\n.xterm .xterm-screen {\n position: relative;\n}\n\n.xterm .xterm-screen canvas {\n position: absolute;\n left: 0;\n top: 0;\n}\n\n.xterm .xterm-scroll-area {\n visibility: hidden;\n}\n\n.xterm-char-measure-element {\n display: inline-block;\n visibility: hidden;\n position: absolute;\n top: 0;\n left: -9999em;\n line-height: normal;\n}\n\n.xterm {\n cursor: text;\n}\n\n.xterm.enable-mouse-events {\n /* When mouse events are enabled (eg. tmux), revert to the standard pointer cursor */\n cursor: default;\n}\n\n.xterm.xterm-cursor-pointer {\n cursor: pointer;\n}\n\n.xterm.column-select.focus {\n /* Column selection mode */\n cursor: crosshair;\n}\n\n.xterm .xterm-accessibility,\n.xterm .xterm-message {\n position: absolute;\n left: 0;\n top: 0;\n bottom: 0;\n right: 0;\n z-index: 10;\n color: transparent;\n}\n\n.xterm .live-region {\n position: absolute;\n left: -9999px;\n width: 1px;\n height: 1px;\n overflow: hidden;\n}\n\n.xterm-dim {\n opacity: 0.5;\n}\n\n.xterm-underline {\n text-decoration: underline;\n}\n',"",{version:3,sources:["webpack://./../../node_modules/xterm/css/xterm.css"],names:[],mappings:"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+BE;;AAEF;;EAEE;;AAEF;IACI,kBAAkB;IAClB,iBAAiB;IACjB,qBAAqB;IACrB,yBAAyB;AAC7B;;AAEA;;IAEI,aAAa;AACjB;;AAEA;IACI,kBAAkB;IAClB,MAAM;IACN;;;MAGE;IACF,UAAU;AACd;;AAEA;IACI,UAAU;IACV,SAAS;IACT,SAAS;IACT,uFAAuF;IACvF,kBAAkB;IAClB,UAAU;IACV,aAAa;IACb,MAAM;IACN,QAAQ;IACR,SAAS;IACT,WAAW;IACX,sFAAsF;IACtF,mBAAmB;IACnB,gBAAgB;IAChB,YAAY;AAChB;;AAEA;IACI,uDAAuD;IACvD,gBAAgB;IAChB,WAAW;IACX,aAAa;IACb,kBAAkB;IAClB,mBAAmB;IACnB,UAAU;AACd;;AAEA;IACI,cAAc;AAClB;;AAEA;IACI,gFAAgF;IAChF,sBAAsB;IACtB,kBAAkB;IAClB,eAAe;IACf,kBAAkB;IAClB,QAAQ;IACR,OAAO;IACP,MAAM;IACN,SAAS;AACb;;AAEA;IACI,kBAAkB;AACtB;;AAEA;IACI,kBAAkB;IAClB,OAAO;IACP,MAAM;AACV;;AAEA;IACI,kBAAkB;AACtB;;AAEA;IACI,qBAAqB;IACrB,kBAAkB;IAClB,kBAAkB;IAClB,MAAM;IACN,aAAa;IACb,mBAAmB;AACvB;;AAEA;IACI,YAAY;AAChB;;AAEA;IACI,oFAAoF;IACpF,eAAe;AACnB;;AAEA;IACI,eAAe;AACnB;;AAEA;IACI,0BAA0B;IAC1B,iBAAiB;AACrB;;AAEA;;IAEI,kBAAkB;IAClB,OAAO;IACP,MAAM;IACN,SAAS;IACT,QAAQ;IACR,WAAW;IACX,kBAAkB;AACtB;;AAEA;IACI,kBAAkB;IAClB,aAAa;IACb,UAAU;IACV,WAAW;IACX,gBAAgB;AACpB;;AAEA;IACI,YAAY;AAChB;;AAEA;IACI,0BAA0B;AAC9B",sourcesContent:['/**\n * Copyright (c) 2014 The xterm.js authors. All rights reserved.\n * Copyright (c) 2012-2013, Christopher Jeffrey (MIT License)\n * https://github.com/chjj/term.js\n * @license MIT\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the "Software"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n *\n * Originally forked from (with the author\'s permission):\n * Fabrice Bellard\'s javascript vt100 for jslinux:\n * http://bellard.org/jslinux/\n * Copyright (c) 2011 Fabrice Bellard\n * The original design remains. The terminal itself\n * has been extended to include xterm CSI codes, among\n * other features.\n */\n\n/**\n * Default styles for xterm.js\n */\n\n.xterm {\n position: relative;\n user-select: none;\n -ms-user-select: none;\n -webkit-user-select: none;\n}\n\n.xterm.focus,\n.xterm:focus {\n outline: none;\n}\n\n.xterm .xterm-helpers {\n position: absolute;\n top: 0;\n /**\n * The z-index of the helpers must be higher than the canvases in order for\n * IMEs to appear on top.\n */\n z-index: 5;\n}\n\n.xterm .xterm-helper-textarea {\n padding: 0;\n border: 0;\n margin: 0;\n /* Move textarea out of the screen to the far left, so that the cursor is not visible */\n position: absolute;\n opacity: 0;\n left: -9999em;\n top: 0;\n width: 0;\n height: 0;\n z-index: -5;\n /** Prevent wrapping so the IME appears against the textarea at the correct position */\n white-space: nowrap;\n overflow: hidden;\n resize: none;\n}\n\n.xterm .composition-view {\n /* TODO: Composition position got messed up somewhere */\n background: #000;\n color: #FFF;\n display: none;\n position: absolute;\n white-space: nowrap;\n z-index: 1;\n}\n\n.xterm .composition-view.active {\n display: block;\n}\n\n.xterm .xterm-viewport {\n /* On OS X this is required in order for the scroll bar to appear fully opaque */\n background-color: #000;\n overflow-y: scroll;\n cursor: default;\n position: absolute;\n right: 0;\n left: 0;\n top: 0;\n bottom: 0;\n}\n\n.xterm .xterm-screen {\n position: relative;\n}\n\n.xterm .xterm-screen canvas {\n position: absolute;\n left: 0;\n top: 0;\n}\n\n.xterm .xterm-scroll-area {\n visibility: hidden;\n}\n\n.xterm-char-measure-element {\n display: inline-block;\n visibility: hidden;\n position: absolute;\n top: 0;\n left: -9999em;\n line-height: normal;\n}\n\n.xterm {\n cursor: text;\n}\n\n.xterm.enable-mouse-events {\n /* When mouse events are enabled (eg. tmux), revert to the standard pointer cursor */\n cursor: default;\n}\n\n.xterm.xterm-cursor-pointer {\n cursor: pointer;\n}\n\n.xterm.column-select.focus {\n /* Column selection mode */\n cursor: crosshair;\n}\n\n.xterm .xterm-accessibility,\n.xterm .xterm-message {\n position: absolute;\n left: 0;\n top: 0;\n bottom: 0;\n right: 0;\n z-index: 10;\n color: transparent;\n}\n\n.xterm .live-region {\n position: absolute;\n left: -9999px;\n width: 1px;\n height: 1px;\n overflow: hidden;\n}\n\n.xterm-dim {\n opacity: 0.5;\n}\n\n.xterm-underline {\n text-decoration: underline;\n}\n'],sourceRoot:""}]);const a=s},609:e=>{"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r=e(t);return t[2]?"@media ".concat(t[2]," {").concat(r,"}"):r})).join("")},t.i=function(e,r,i){"string"==typeof e&&(e=[[null,e,""]]);var n={};if(i)for(var o=0;o{"use strict";function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,i=new Array(t);r0&&t-1 in e)}A.fn=A.prototype={jquery:w,constructor:A,length:0,toArray:function(){return a.call(this)},get:function(e){return null==e?a.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=A.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return A.each(this,e)},map:function(e){return this.pushStack(A.map(this,(function(t,r){return e.call(t,r,t)})))},slice:function(){return this.pushStack(a.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(A.grep(this,(function(e,t){return(t+1)%2})))},odd:function(){return this.pushStack(A.grep(this,(function(e,t){return t%2})))},eq:function(e){var t=this.length,r=+e+(e<0?t:0);return this.pushStack(r>=0&&r+~]|[\\x20\\t\\r\\n\\f])[\\x20\\t\\r\\n\\f]*"),K=new RegExp(B+"|>"),V=new RegExp(N),G=new RegExp("^"+j+"$"),X={ID:new RegExp("^#("+j+")"),CLASS:new RegExp("^\\.("+j+")"),TAG:new RegExp("^("+j+"|[*])"),ATTR:new RegExp("^"+F),PSEUDO:new RegExp("^"+N),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\([\\x20\\t\\r\\n\\f]*(even|odd|(([+-]|)(\\d*)n|)[\\x20\\t\\r\\n\\f]*(?:([+-]|)[\\x20\\t\\r\\n\\f]*(\\d+)|))[\\x20\\t\\r\\n\\f]*\\)|)","i"),bool:new RegExp("^(?:"+H+")$","i"),needsContext:new RegExp("^[\\x20\\t\\r\\n\\f]*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\([\\x20\\t\\r\\n\\f]*((?:-\\d)?\\d*)[\\x20\\t\\r\\n\\f]*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,$=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,Q=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}[\\x20\\t\\r\\n\\f]?|\\\\([^\\r\\n\\f])","g"),re=function(e,t){var r="0x"+e.slice(1)-65536;return t||(r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320))},ie=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ne=function(e,t){return t?"\0"===e?"�":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){f()},se=be((function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()}),{dir:"parentNode",next:"legend"});try{P.apply(R=I.call(S.childNodes),S.childNodes),R[S.childNodes.length].nodeType}catch(e){P={apply:R.length?function(e,t){O.apply(e,I.call(t))}:function(e,t){for(var r=e.length,i=0;e[r++]=t[i++];);e.length=r-1}}}function ae(e,t,i,n){var o,a,l,u,h,p,g,y=t&&t.ownerDocument,S=t?t.nodeType:9;if(i=i||[],"string"!=typeof e||!e||1!==S&&9!==S&&11!==S)return i;if(!n&&(f(t),t=t||d,_)){if(11!==S&&(h=Q.exec(e)))if(o=h[1]){if(9===S){if(!(l=t.getElementById(o)))return i;if(l.id===o)return i.push(l),i}else if(y&&(l=y.getElementById(o))&&m(t,l)&&l.id===o)return i.push(l),i}else{if(h[2])return P.apply(i,t.getElementsByTagName(e)),i;if((o=h[3])&&r.getElementsByClassName&&t.getElementsByClassName)return P.apply(i,t.getElementsByClassName(o)),i}if(r.qsa&&!L[e+" "]&&(!v||!v.test(e))&&(1!==S||"object"!==t.nodeName.toLowerCase())){if(g=e,y=t,1===S&&(K.test(e)||z.test(e))){for((y=ee.test(e)&&ge(t.parentNode)||t)===t&&r.scope||((u=t.getAttribute("id"))?u=u.replace(ie,ne):t.setAttribute("id",u=b)),a=(p=s(e)).length;a--;)p[a]=(u?"#"+u:":scope")+" "+me(p[a]);g=p.join(",")}try{return P.apply(i,y.querySelectorAll(g)),i}catch(t){L(e,!0)}finally{u===b&&t.removeAttribute("id")}}}return c(e.replace(q,"$1"),t,i,n)}function ce(){var e=[];return function t(r,n){return e.push(r+" ")>i.cacheLength&&delete t[e.shift()],t[r+" "]=n}}function le(e){return e[b]=!0,e}function ue(e){var t=d.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function he(e,t){for(var r=e.split("|"),n=r.length;n--;)i.attrHandle[r[n]]=t}function fe(e,t){var r=t&&e,i=r&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(i)return i;if(r)for(;r=r.nextSibling;)if(r===t)return-1;return e?1:-1}function de(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function pe(e){return function(t){var r=t.nodeName.toLowerCase();return("input"===r||"button"===r)&&t.type===e}}function _e(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&se(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function ve(e){return le((function(t){return t=+t,le((function(r,i){for(var n,o=e([],r.length,t),s=o.length;s--;)r[n=o[s]]&&(r[n]=!(i[n]=r[n]))}))}))}function ge(e){return e&&void 0!==e.getElementsByTagName&&e}for(t in r=ae.support={},o=ae.isXML=function(e){var t=e&&e.namespaceURI,r=e&&(e.ownerDocument||e).documentElement;return!Y.test(t||r&&r.nodeName||"HTML")},f=ae.setDocument=function(e){var t,n,s=e?e.ownerDocument||e:S;return s!=d&&9===s.nodeType&&s.documentElement?(p=(d=s).documentElement,_=!o(d),S!=d&&(n=d.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),r.scope=ue((function(e){return p.appendChild(e).appendChild(d.createElement("div")),void 0!==e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length})),r.attributes=ue((function(e){return e.className="i",!e.getAttribute("className")})),r.getElementsByTagName=ue((function(e){return e.appendChild(d.createComment("")),!e.getElementsByTagName("*").length})),r.getElementsByClassName=Z.test(d.getElementsByClassName),r.getById=ue((function(e){return p.appendChild(e).id=b,!d.getElementsByName||!d.getElementsByName(b).length})),r.getById?(i.filter.ID=function(e){var t=e.replace(te,re);return function(e){return e.getAttribute("id")===t}},i.find.ID=function(e,t){if(void 0!==t.getElementById&&_){var r=t.getElementById(e);return r?[r]:[]}}):(i.filter.ID=function(e){var t=e.replace(te,re);return function(e){var r=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return r&&r.value===t}},i.find.ID=function(e,t){if(void 0!==t.getElementById&&_){var r,i,n,o=t.getElementById(e);if(o){if((r=o.getAttributeNode("id"))&&r.value===e)return[o];for(n=t.getElementsByName(e),i=0;o=n[i++];)if((r=o.getAttributeNode("id"))&&r.value===e)return[o]}return[]}}),i.find.TAG=r.getElementsByTagName?function(e,t){return void 0!==t.getElementsByTagName?t.getElementsByTagName(e):r.qsa?t.querySelectorAll(e):void 0}:function(e,t){var r,i=[],n=0,o=t.getElementsByTagName(e);if("*"===e){for(;r=o[n++];)1===r.nodeType&&i.push(r);return i}return o},i.find.CLASS=r.getElementsByClassName&&function(e,t){if(void 0!==t.getElementsByClassName&&_)return t.getElementsByClassName(e)},g=[],v=[],(r.qsa=Z.test(d.querySelectorAll))&&(ue((function(e){var t;p.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]=[\\x20\\t\\r\\n\\f]*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\[[\\x20\\t\\r\\n\\f]*(?:value|"+H+")"),e.querySelectorAll("[id~="+b+"-]").length||v.push("~="),(t=d.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\[[\\x20\\t\\r\\n\\f]*name[\\x20\\t\\r\\n\\f]*=[\\x20\\t\\r\\n\\f]*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+b+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")})),ue((function(e){e.innerHTML="";var t=d.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name[\\x20\\t\\r\\n\\f]*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),p.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")}))),(r.matchesSelector=Z.test(y=p.matches||p.webkitMatchesSelector||p.mozMatchesSelector||p.oMatchesSelector||p.msMatchesSelector))&&ue((function(e){r.disconnectedMatch=y.call(e,"*"),y.call(e,"[s!='']:x"),g.push("!=",N)})),v=v.length&&new RegExp(v.join("|")),g=g.length&&new RegExp(g.join("|")),t=Z.test(p.compareDocumentPosition),m=t||Z.test(p.contains)?function(e,t){var r=9===e.nodeType?e.documentElement:e,i=t&&t.parentNode;return e===i||!(!i||1!==i.nodeType||!(r.contains?r.contains(i):e.compareDocumentPosition&&16&e.compareDocumentPosition(i)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},k=t?function(e,t){if(e===t)return h=!0,0;var i=!e.compareDocumentPosition-!t.compareDocumentPosition;return i||(1&(i=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!r.sortDetached&&t.compareDocumentPosition(e)===i?e==d||e.ownerDocument==S&&m(S,e)?-1:t==d||t.ownerDocument==S&&m(S,t)?1:u?M(u,e)-M(u,t):0:4&i?-1:1)}:function(e,t){if(e===t)return h=!0,0;var r,i=0,n=e.parentNode,o=t.parentNode,s=[e],a=[t];if(!n||!o)return e==d?-1:t==d?1:n?-1:o?1:u?M(u,e)-M(u,t):0;if(n===o)return fe(e,t);for(r=e;r=r.parentNode;)s.unshift(r);for(r=t;r=r.parentNode;)a.unshift(r);for(;s[i]===a[i];)i++;return i?fe(s[i],a[i]):s[i]==S?-1:a[i]==S?1:0},d):d},ae.matches=function(e,t){return ae(e,null,null,t)},ae.matchesSelector=function(e,t){if(f(e),r.matchesSelector&&_&&!L[t+" "]&&(!g||!g.test(t))&&(!v||!v.test(t)))try{var i=y.call(e,t);if(i||r.disconnectedMatch||e.document&&11!==e.document.nodeType)return i}catch(e){L(t,!0)}return ae(t,d,null,[e]).length>0},ae.contains=function(e,t){return(e.ownerDocument||e)!=d&&f(e),m(e,t)},ae.attr=function(e,t){(e.ownerDocument||e)!=d&&f(e);var n=i.attrHandle[t.toLowerCase()],o=n&&T.call(i.attrHandle,t.toLowerCase())?n(e,t,!_):void 0;return void 0!==o?o:r.attributes||!_?e.getAttribute(t):(o=e.getAttributeNode(t))&&o.specified?o.value:null},ae.escape=function(e){return(e+"").replace(ie,ne)},ae.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},ae.uniqueSort=function(e){var t,i=[],n=0,o=0;if(h=!r.detectDuplicates,u=!r.sortStable&&e.slice(0),e.sort(k),h){for(;t=e[o++];)t===e[o]&&(n=i.push(o));for(;n--;)e.splice(i[n],1)}return u=null,e},n=ae.getText=function(e){var t,r="",i=0,o=e.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)r+=n(e)}else if(3===o||4===o)return e.nodeValue}else for(;t=e[i++];)r+=n(t);return r},(i=ae.selectors={cacheLength:50,createPseudo:le,match:X,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,re),e[3]=(e[3]||e[4]||e[5]||"").replace(te,re),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||ae.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&ae.error(e[0]),e},PSEUDO:function(e){var t,r=!e[6]&&e[2];return X.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":r&&V.test(r)&&(t=s(r,!0))&&(t=r.indexOf(")",r.length-t)-r.length)&&(e[0]=e[0].slice(0,t),e[2]=r.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,re).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=A[e+" "];return t||(t=new RegExp("(^|[\\x20\\t\\r\\n\\f])"+e+"("+B+"|$)"))&&A(e,(function(e){return t.test("string"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute("class")||"")}))},ATTR:function(e,t,r){return function(i){var n=ae.attr(i,e);return null==n?"!="===t:!t||(n+="","="===t?n===r:"!="===t?n!==r:"^="===t?r&&0===n.indexOf(r):"*="===t?r&&n.indexOf(r)>-1:"$="===t?r&&n.slice(-r.length)===r:"~="===t?(" "+n.replace(W," ")+" ").indexOf(r)>-1:"|="===t&&(n===r||n.slice(0,r.length+1)===r+"-"))}},CHILD:function(e,t,r,i,n){var o="nth"!==e.slice(0,3),s="last"!==e.slice(-4),a="of-type"===t;return 1===i&&0===n?function(e){return!!e.parentNode}:function(t,r,c){var l,u,h,f,d,p,_=o!==s?"nextSibling":"previousSibling",v=t.parentNode,g=a&&t.nodeName.toLowerCase(),y=!c&&!a,m=!1;if(v){if(o){for(;_;){for(f=t;f=f[_];)if(a?f.nodeName.toLowerCase()===g:1===f.nodeType)return!1;p=_="only"===e&&!p&&"nextSibling"}return!0}if(p=[s?v.firstChild:v.lastChild],s&&y){for(m=(d=(l=(u=(h=(f=v)[b]||(f[b]={}))[f.uniqueID]||(h[f.uniqueID]={}))[e]||[])[0]===C&&l[1])&&l[2],f=d&&v.childNodes[d];f=++d&&f&&f[_]||(m=d=0)||p.pop();)if(1===f.nodeType&&++m&&f===t){u[e]=[C,d,m];break}}else if(y&&(m=d=(l=(u=(h=(f=t)[b]||(f[b]={}))[f.uniqueID]||(h[f.uniqueID]={}))[e]||[])[0]===C&&l[1]),!1===m)for(;(f=++d&&f&&f[_]||(m=d=0)||p.pop())&&((a?f.nodeName.toLowerCase()!==g:1!==f.nodeType)||!++m||(y&&((u=(h=f[b]||(f[b]={}))[f.uniqueID]||(h[f.uniqueID]={}))[e]=[C,m]),f!==t)););return(m-=n)===i||m%i==0&&m/i>=0}}},PSEUDO:function(e,t){var r,n=i.pseudos[e]||i.setFilters[e.toLowerCase()]||ae.error("unsupported pseudo: "+e);return n[b]?n(t):n.length>1?(r=[e,e,"",t],i.setFilters.hasOwnProperty(e.toLowerCase())?le((function(e,r){for(var i,o=n(e,t),s=o.length;s--;)e[i=M(e,o[s])]=!(r[i]=o[s])})):function(e){return n(e,0,r)}):n}},pseudos:{not:le((function(e){var t=[],r=[],i=a(e.replace(q,"$1"));return i[b]?le((function(e,t,r,n){for(var o,s=i(e,null,n,[]),a=e.length;a--;)(o=s[a])&&(e[a]=!(t[a]=o))})):function(e,n,o){return t[0]=e,i(t,null,o,r),t[0]=null,!r.pop()}})),has:le((function(e){return function(t){return ae(e,t).length>0}})),contains:le((function(e){return e=e.replace(te,re),function(t){return(t.textContent||n(t)).indexOf(e)>-1}})),lang:le((function(e){return G.test(e||"")||ae.error("unsupported lang: "+e),e=e.replace(te,re).toLowerCase(),function(t){var r;do{if(r=_?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(r=r.toLowerCase())===e||0===r.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}})),target:function(t){var r=e.location&&e.location.hash;return r&&r.slice(1)===t.id},root:function(e){return e===p},focus:function(e){return e===d.activeElement&&(!d.hasFocus||d.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:_e(!1),disabled:_e(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!i.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return $.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:ve((function(){return[0]})),last:ve((function(e,t){return[t-1]})),eq:ve((function(e,t,r){return[r<0?r+t:r]})),even:ve((function(e,t){for(var r=0;rt?t:r;--i>=0;)e.push(i);return e})),gt:ve((function(e,t,r){for(var i=r<0?r+t:r;++i1?function(t,r,i){for(var n=e.length;n--;)if(!e[n](t,r,i))return!1;return!0}:e[0]}function Ce(e,t,r,i,n){for(var o,s=[],a=0,c=e.length,l=null!=t;a-1&&(o[l]=!(s[l]=h))}}else g=Ce(g===s?g.splice(p,g.length):g),n?n(null,s,g,c):P.apply(s,g)}))}function Ae(e){for(var t,r,n,o=e.length,s=i.relative[e[0].type],a=s||i.relative[" "],c=s?1:0,u=be((function(e){return e===t}),a,!0),h=be((function(e){return M(t,e)>-1}),a,!0),f=[function(e,r,i){var n=!s&&(i||r!==l)||((t=r).nodeType?u(e,r,i):h(e,r,i));return t=null,n}];c1&&Se(f),c>1&&me(e.slice(0,c-1).concat({value:" "===e[c-2].type?"*":""})).replace(q,"$1"),r,c0,n=e.length>0,o=function(o,s,a,c,u){var h,p,v,g=0,y="0",m=o&&[],b=[],S=l,w=o||n&&i.find.TAG("*",u),A=C+=null==S?1:Math.random()||.1,x=w.length;for(u&&(l=s==d||s||u);y!==x&&null!=(h=w[y]);y++){if(n&&h){for(p=0,s||h.ownerDocument==d||(f(h),a=!_);v=e[p++];)if(v(h,s||d,a)){c.push(h);break}u&&(C=A)}r&&((h=!v&&h)&&g--,o&&m.push(h))}if(g+=y,r&&y!==g){for(p=0;v=t[p++];)v(m,b,s,a);if(o){if(g>0)for(;y--;)m[y]||b[y]||(b[y]=D.call(c));b=Ce(b)}P.apply(c,b),u&&!o&&b.length>0&&g+t.length>1&&ae.uniqueSort(c)}return u&&(C=A,l=S),m};return r?le(o):o}(o,n))).selector=e}return a},c=ae.select=function(e,t,r,n){var o,c,l,u,h,f="function"==typeof e&&e,d=!n&&s(e=f.selector||e);if(r=r||[],1===d.length){if((c=d[0]=d[0].slice(0)).length>2&&"ID"===(l=c[0]).type&&9===t.nodeType&&_&&i.relative[c[1].type]){if(!(t=(i.find.ID(l.matches[0].replace(te,re),t)||[])[0]))return r;f&&(t=t.parentNode),e=e.slice(c.shift().value.length)}for(o=X.needsContext.test(e)?0:c.length;o--&&(l=c[o],!i.relative[u=l.type]);)if((h=i.find[u])&&(n=h(l.matches[0].replace(te,re),ee.test(c[0].type)&&ge(t.parentNode)||t))){if(c.splice(o,1),!(e=n.length&&me(c)))return P.apply(r,n),r;break}}return(f||a(e,d))(n,t,!_,r,!t||ee.test(e)&&ge(t.parentNode)||t),r},r.sortStable=b.split("").sort(k).join("")===b,r.detectDuplicates=!!h,f(),r.sortDetached=ue((function(e){return 1&e.compareDocumentPosition(d.createElement("fieldset"))})),ue((function(e){return e.innerHTML="","#"===e.firstChild.getAttribute("href")}))||he("type|href|height|width",(function(e,t,r){if(!r)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)})),r.attributes&&ue((function(e){return e.innerHTML="",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")}))||he("value",(function(e,t,r){if(!r&&"input"===e.nodeName.toLowerCase())return e.defaultValue})),ue((function(e){return null==e.getAttribute("disabled")}))||he(H,(function(e,t,r){var i;if(!r)return!0===e[t]?t.toLowerCase():(i=e.getAttributeNode(t))&&i.specified?i.value:null})),ae}(i);A.find=E,A.expr=E.selectors,A.expr[":"]=A.expr.pseudos,A.uniqueSort=A.unique=E.uniqueSort,A.text=E.getText,A.isXMLDoc=E.isXML,A.contains=E.contains,A.escapeSelector=E.escape;var L=function(e,t,r){for(var i=[],n=void 0!==r;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(n&&A(e).is(r))break;i.push(e)}return i},k=function(e,t){for(var r=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&r.push(e);return r},T=A.expr.match.needsContext;function R(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var D=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function O(e,t,r){return g(t)?A.grep(e,(function(e,i){return!!t.call(e,i,e)!==r})):t.nodeType?A.grep(e,(function(e){return e===t!==r})):"string"!=typeof t?A.grep(e,(function(e){return u.call(t,e)>-1!==r})):A.filter(t,e,r)}A.filter=function(e,t,r){var i=t[0];return r&&(e=":not("+e+")"),1===t.length&&1===i.nodeType?A.find.matchesSelector(i,e)?[i]:[]:A.find.matches(e,A.grep(t,(function(e){return 1===e.nodeType})))},A.fn.extend({find:function(e){var t,r,i=this.length,n=this;if("string"!=typeof e)return this.pushStack(A(e).filter((function(){for(t=0;t1?A.uniqueSort(r):r},filter:function(e){return this.pushStack(O(this,e||[],!1))},not:function(e){return this.pushStack(O(this,e||[],!0))},is:function(e){return!!O(this,"string"==typeof e&&T.test(e)?A(e):e||[],!1).length}});var P,I=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(A.fn.init=function(e,t,r){var i,n;if(!e)return this;if(r=r||P,"string"==typeof e){if(!(i="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:I.exec(e))||!i[1]&&t)return!t||t.jquery?(t||r).find(e):this.constructor(t).find(e);if(i[1]){if(t=t instanceof A?t[0]:t,A.merge(this,A.parseHTML(i[1],t&&t.nodeType?t.ownerDocument||t:m,!0)),D.test(i[1])&&A.isPlainObject(t))for(i in t)g(this[i])?this[i](t[i]):this.attr(i,t[i]);return this}return(n=m.getElementById(i[2]))&&(this[0]=n,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):g(e)?void 0!==r.ready?r.ready(e):e(A):A.makeArray(e,this)}).prototype=A.fn,P=A(m);var M=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function B(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}A.fn.extend({has:function(e){var t=A(e,this),r=t.length;return this.filter((function(){for(var e=0;e-1:1===r.nodeType&&A.find.matchesSelector(r,e))){o.push(r);break}return this.pushStack(o.length>1?A.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?u.call(A(e),this[0]):u.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(A.uniqueSort(A.merge(this.get(),A(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),A.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return L(e,"parentNode")},parentsUntil:function(e,t,r){return L(e,"parentNode",r)},next:function(e){return B(e,"nextSibling")},prev:function(e){return B(e,"previousSibling")},nextAll:function(e){return L(e,"nextSibling")},prevAll:function(e){return L(e,"previousSibling")},nextUntil:function(e,t,r){return L(e,"nextSibling",r)},prevUntil:function(e,t,r){return L(e,"previousSibling",r)},siblings:function(e){return k((e.parentNode||{}).firstChild,e)},children:function(e){return k(e.firstChild)},contents:function(e){return null!=e.contentDocument&&s(e.contentDocument)?e.contentDocument:(R(e,"template")&&(e=e.content||e),A.merge([],e.childNodes))}},(function(e,t){A.fn[e]=function(r,i){var n=A.map(this,t,r);return"Until"!==e.slice(-5)&&(i=r),i&&"string"==typeof i&&(n=A.filter(i,n)),this.length>1&&(H[e]||A.uniqueSort(n),M.test(e)&&n.reverse()),this.pushStack(n)}}));var j=/[^\x20\t\r\n\f]+/g;function F(e){return e}function N(e){throw e}function W(e,t,r,i){var n;try{e&&g(n=e.promise)?n.call(e).done(t).fail(r):e&&g(n=e.then)?n.call(e,t,r):t.apply(void 0,[e].slice(i))}catch(e){r.apply(void 0,[e])}}A.Callbacks=function(e){e="string"==typeof e?function(e){var t={};return A.each(e.match(j)||[],(function(e,r){t[r]=!0})),t}(e):A.extend({},e);var t,r,i,n,o=[],s=[],a=-1,c=function(){for(n=n||e.once,i=t=!0;s.length;a=-1)for(r=s.shift();++a-1;)o.splice(r,1),r<=a&&a--})),this},has:function(e){return e?A.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return n=s=[],o=r="",this},disabled:function(){return!o},lock:function(){return n=s=[],r||t||(o=r=""),this},locked:function(){return!!n},fireWith:function(e,r){return n||(r=[e,(r=r||[]).slice?r.slice():r],s.push(r),t||c()),this},fire:function(){return l.fireWith(this,arguments),this},fired:function(){return!!i}};return l},A.extend({Deferred:function(e){var t=[["notify","progress",A.Callbacks("memory"),A.Callbacks("memory"),2],["resolve","done",A.Callbacks("once memory"),A.Callbacks("once memory"),0,"resolved"],["reject","fail",A.Callbacks("once memory"),A.Callbacks("once memory"),1,"rejected"]],r="pending",n={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},catch:function(e){return n.then(null,e)},pipe:function(){var e=arguments;return A.Deferred((function(r){A.each(t,(function(t,i){var n=g(e[i[4]])&&e[i[4]];o[i[1]]((function(){var e=n&&n.apply(this,arguments);e&&g(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[i[0]+"With"](this,n?[e]:arguments)}))})),e=null})).promise()},then:function(e,r,n){var o=0;function s(e,t,r,n){return function(){var a=this,c=arguments,l=function(){var i,l;if(!(e=o&&(r!==N&&(a=void 0,c=[i]),t.rejectWith(a,c))}};e?u():(A.Deferred.getStackHook&&(u.stackTrace=A.Deferred.getStackHook()),i.setTimeout(u))}}return A.Deferred((function(i){t[0][3].add(s(0,i,g(n)?n:F,i.notifyWith)),t[1][3].add(s(0,i,g(e)?e:F)),t[2][3].add(s(0,i,g(r)?r:N))})).promise()},promise:function(e){return null!=e?A.extend(e,n):n}},o={};return A.each(t,(function(e,i){var s=i[2],a=i[5];n[i[1]]=s.add,a&&s.add((function(){r=a}),t[3-e][2].disable,t[3-e][3].disable,t[0][2].lock,t[0][3].lock),s.add(i[3].fire),o[i[0]]=function(){return o[i[0]+"With"](this===o?void 0:this,arguments),this},o[i[0]+"With"]=s.fireWith})),n.promise(o),e&&e.call(o,o),o},when:function(e){var t=arguments.length,r=t,i=Array(r),n=a.call(arguments),o=A.Deferred(),s=function(e){return function(r){i[e]=this,n[e]=arguments.length>1?a.call(arguments):r,--t||o.resolveWith(i,n)}};if(t<=1&&(W(e,o.done(s(r)).resolve,o.reject,!t),"pending"===o.state()||g(n[r]&&n[r].then)))return o.then();for(;r--;)W(n[r],s(r),o.reject);return o.promise()}});var q=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;A.Deferred.exceptionHook=function(e,t){i.console&&i.console.warn&&e&&q.test(e.name)&&i.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},A.readyException=function(e){i.setTimeout((function(){throw e}))};var U=A.Deferred();function z(){m.removeEventListener("DOMContentLoaded",z),i.removeEventListener("load",z),A.ready()}A.fn.ready=function(e){return U.then(e).catch((function(e){A.readyException(e)})),this},A.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--A.readyWait:A.isReady)||(A.isReady=!0,!0!==e&&--A.readyWait>0||U.resolveWith(m,[A]))}}),A.ready.then=U.then,"complete"===m.readyState||"loading"!==m.readyState&&!m.documentElement.doScroll?i.setTimeout(A.ready):(m.addEventListener("DOMContentLoaded",z),i.addEventListener("load",z));var K=function(e,t,r,i,n,o,s){var a=0,c=e.length,l=null==r;if("object"===C(r))for(a in n=!0,r)K(e,t,a,r[a],!0,o,s);else if(void 0!==i&&(n=!0,g(i)||(s=!0),l&&(s?(t.call(e,i),t=null):(l=t,t=function(e,t,r){return l.call(A(e),r)})),t))for(;a1,null,!0)},removeData:function(e){return this.each((function(){Q.remove(this,e)}))}}),A.extend({queue:function(e,t,r){var i;if(e)return t=(t||"fx")+"queue",i=Z.get(e,t),r&&(!i||Array.isArray(r)?i=Z.access(e,t,A.makeArray(r)):i.push(r)),i||[]},dequeue:function(e,t){t=t||"fx";var r=A.queue(e,t),i=r.length,n=r.shift(),o=A._queueHooks(e,t);"inprogress"===n&&(n=r.shift(),i--),n&&("fx"===t&&r.unshift("inprogress"),delete o.stop,n.call(e,(function(){A.dequeue(e,t)}),o)),!i&&o&&o.empty.fire()},_queueHooks:function(e,t){var r=t+"queueHooks";return Z.get(e,r)||Z.access(e,r,{empty:A.Callbacks("once memory").add((function(){Z.remove(e,[t+"queue",r])}))})}}),A.fn.extend({queue:function(e,t){var r=2;return"string"!=typeof e&&(t=e,e="fx",r--),arguments.length\x20\t\r\n\f]*)/i,ye=/^$|^module$|\/(?:java|ecma)script/i;pe=m.createDocumentFragment().appendChild(m.createElement("div")),(_e=m.createElement("input")).setAttribute("type","radio"),_e.setAttribute("checked","checked"),_e.setAttribute("name","t"),pe.appendChild(_e),v.checkClone=pe.cloneNode(!0).cloneNode(!0).lastChild.checked,pe.innerHTML="",v.noCloneChecked=!!pe.cloneNode(!0).lastChild.defaultValue,pe.innerHTML="",v.option=!!pe.lastChild;var me={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function be(e,t){var r;return r=void 0!==e.getElementsByTagName?e.getElementsByTagName(t||"*"):void 0!==e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&R(e,t)?A.merge([e],r):r}function Se(e,t){for(var r=0,i=e.length;r",""]);var Ce=/<|&#?\w+;/;function we(e,t,r,i,n){for(var o,s,a,c,l,u,h=t.createDocumentFragment(),f=[],d=0,p=e.length;d-1)n&&n.push(o);else if(l=ae(o),s=be(h.appendChild(o),"script"),l&&Se(s),r)for(u=0;o=s[u++];)ye.test(o.type||"")&&r.push(o);return h}var Ae=/^([^.]*)(?:\.(.+)|)/;function xe(){return!0}function Ee(){return!1}function Le(e,t){return e===function(){try{return m.activeElement}catch(e){}}()==("focus"===t)}function ke(e,t,r,i,n,o){var s,a;if("object"==typeof t){for(a in"string"!=typeof r&&(i=i||r,r=void 0),t)ke(e,a,r,i,t[a],o);return e}if(null==i&&null==n?(n=r,i=r=void 0):null==n&&("string"==typeof r?(n=i,i=void 0):(n=i,i=r,r=void 0)),!1===n)n=Ee;else if(!n)return e;return 1===o&&(s=n,(n=function(e){return A().off(e),s.apply(this,arguments)}).guid=s.guid||(s.guid=A.guid++)),e.each((function(){A.event.add(this,t,n,i,r)}))}function Te(e,t,r){r?(Z.set(e,t,!1),A.event.add(e,t,{namespace:!1,handler:function(e){var i,n,o=Z.get(this,t);if(1&e.isTrigger&&this[t]){if(o.length)(A.event.special[t]||{}).delegateType&&e.stopPropagation();else if(o=a.call(arguments),Z.set(this,t,o),i=r(this,t),this[t](),o!==(n=Z.get(this,t))||i?Z.set(this,t,!1):n={},o!==n)return e.stopImmediatePropagation(),e.preventDefault(),n&&n.value}else o.length&&(Z.set(this,t,{value:A.event.trigger(A.extend(o[0],A.Event.prototype),o.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Z.get(e,t)&&A.event.add(e,t,xe)}A.event={global:{},add:function(e,t,r,i,n){var o,s,a,c,l,u,h,f,d,p,_,v=Z.get(e);if($(e))for(r.handler&&(r=(o=r).handler,n=o.selector),n&&A.find.matchesSelector(se,n),r.guid||(r.guid=A.guid++),(c=v.events)||(c=v.events=Object.create(null)),(s=v.handle)||(s=v.handle=function(t){return void 0!==A&&A.event.triggered!==t.type?A.event.dispatch.apply(e,arguments):void 0}),l=(t=(t||"").match(j)||[""]).length;l--;)d=_=(a=Ae.exec(t[l])||[])[1],p=(a[2]||"").split(".").sort(),d&&(h=A.event.special[d]||{},d=(n?h.delegateType:h.bindType)||d,h=A.event.special[d]||{},u=A.extend({type:d,origType:_,data:i,handler:r,guid:r.guid,selector:n,needsContext:n&&A.expr.match.needsContext.test(n),namespace:p.join(".")},o),(f=c[d])||((f=c[d]=[]).delegateCount=0,h.setup&&!1!==h.setup.call(e,i,p,s)||e.addEventListener&&e.addEventListener(d,s)),h.add&&(h.add.call(e,u),u.handler.guid||(u.handler.guid=r.guid)),n?f.splice(f.delegateCount++,0,u):f.push(u),A.event.global[d]=!0)},remove:function(e,t,r,i,n){var o,s,a,c,l,u,h,f,d,p,_,v=Z.hasData(e)&&Z.get(e);if(v&&(c=v.events)){for(l=(t=(t||"").match(j)||[""]).length;l--;)if(d=_=(a=Ae.exec(t[l])||[])[1],p=(a[2]||"").split(".").sort(),d){for(h=A.event.special[d]||{},f=c[d=(i?h.delegateType:h.bindType)||d]||[],a=a[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),s=o=f.length;o--;)u=f[o],!n&&_!==u.origType||r&&r.guid!==u.guid||a&&!a.test(u.namespace)||i&&i!==u.selector&&("**"!==i||!u.selector)||(f.splice(o,1),u.selector&&f.delegateCount--,h.remove&&h.remove.call(e,u));s&&!f.length&&(h.teardown&&!1!==h.teardown.call(e,p,v.handle)||A.removeEvent(e,d,v.handle),delete c[d])}else for(d in c)A.event.remove(e,d+t[l],r,i,!0);A.isEmptyObject(c)&&Z.remove(e,"handle events")}},dispatch:function(e){var t,r,i,n,o,s,a=new Array(arguments.length),c=A.event.fix(e),l=(Z.get(this,"events")||Object.create(null))[c.type]||[],u=A.event.special[c.type]||{};for(a[0]=c,t=1;t=1))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&("click"!==e.type||!0!==l.disabled)){for(o=[],s={},r=0;r-1:A.find(n,this,null,[l]).length),s[n]&&o.push(i);o.length&&a.push({elem:l,handlers:o})}return l=this,c\s*$/g;function Pe(e,t){return R(e,"table")&&R(11!==t.nodeType?t:t.firstChild,"tr")&&A(e).children("tbody")[0]||e}function Ie(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Me(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function He(e,t){var r,i,n,o,s,a;if(1===t.nodeType){if(Z.hasData(e)&&(a=Z.get(e).events))for(n in Z.remove(t,"handle events"),a)for(r=0,i=a[n].length;r1&&"string"==typeof p&&!v.checkClone&&De.test(p))return e.each((function(n){var o=e.eq(n);_&&(t[0]=p.call(this,n,o.html())),je(o,t,r,i)}));if(f&&(o=(n=we(t,e[0].ownerDocument,!1,e,i)).firstChild,1===n.childNodes.length&&(n=o),o||i)){for(a=(s=A.map(be(n,"script"),Ie)).length;h0&&Se(s,!c&&be(e,"script")),a},cleanData:function(e){for(var t,r,i,n=A.event.special,o=0;void 0!==(r=e[o]);o++)if($(r)){if(t=r[Z.expando]){if(t.events)for(i in t.events)n[i]?A.event.remove(r,i):A.removeEvent(r,i,t.handle);r[Z.expando]=void 0}r[Q.expando]&&(r[Q.expando]=void 0)}}}),A.fn.extend({detach:function(e){return Fe(this,e,!0)},remove:function(e){return Fe(this,e)},text:function(e){return K(this,(function(e){return void 0===e?A.text(this):this.empty().each((function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)}))}),null,e,arguments.length)},append:function(){return je(this,arguments,(function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Pe(this,e).appendChild(e)}))},prepend:function(){return je(this,arguments,(function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Pe(this,e);t.insertBefore(e,t.firstChild)}}))},before:function(){return je(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this)}))},after:function(){return je(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)}))},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(A.cleanData(be(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map((function(){return A.clone(this,e,t)}))},html:function(e){return K(this,(function(e){var t=this[0]||{},r=0,i=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Re.test(e)&&!me[(ge.exec(e)||["",""])[1].toLowerCase()]){e=A.htmlPrefilter(e);try{for(;r=0&&(c+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-c-a-.5))||0),c}function rt(e,t,r){var i=We(e),n=(!v.boxSizingReliable()||r)&&"border-box"===A.css(e,"boxSizing",!1,i),o=n,s=ze(e,t,i),a="offset"+t[0].toUpperCase()+t.slice(1);if(Ne.test(s)){if(!r)return s;s="auto"}return(!v.boxSizingReliable()&&n||!v.reliableTrDimensions()&&R(e,"tr")||"auto"===s||!parseFloat(s)&&"inline"===A.css(e,"display",!1,i))&&e.getClientRects().length&&(n="border-box"===A.css(e,"boxSizing",!1,i),(o=a in e)&&(s=e[a])),(s=parseFloat(s)||0)+tt(e,t,r||(n?"border":"content"),o,i,s)+"px"}function it(e,t,r,i,n){return new it.prototype.init(e,t,r,i,n)}A.extend({cssHooks:{opacity:{get:function(e,t){if(t){var r=ze(e,"opacity");return""===r?"1":r}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,r,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var n,o,s,a=Y(t),c=Je.test(t),l=e.style;if(c||(t=Ye(a)),s=A.cssHooks[t]||A.cssHooks[a],void 0===r)return s&&"get"in s&&void 0!==(n=s.get(e,!1,i))?n:l[t];"string"==(o=typeof r)&&(n=ne.exec(r))&&n[1]&&(r=ue(e,t,n),o="number"),null!=r&&r==r&&("number"!==o||c||(r+=n&&n[3]||(A.cssNumber[a]?"":"px")),v.clearCloneStyle||""!==r||0!==t.indexOf("background")||(l[t]="inherit"),s&&"set"in s&&void 0===(r=s.set(e,r,i))||(c?l.setProperty(t,r):l[t]=r))}},css:function(e,t,r,i){var n,o,s,a=Y(t);return Je.test(t)||(t=Ye(a)),(s=A.cssHooks[t]||A.cssHooks[a])&&"get"in s&&(n=s.get(e,!0,r)),void 0===n&&(n=ze(e,t,i)),"normal"===n&&t in Qe&&(n=Qe[t]),""===r||r?(o=parseFloat(n),!0===r||isFinite(o)?o||0:n):n}}),A.each(["height","width"],(function(e,t){A.cssHooks[t]={get:function(e,r,i){if(r)return!$e.test(A.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?rt(e,t,i):qe(e,Ze,(function(){return rt(e,t,i)}))},set:function(e,r,i){var n,o=We(e),s=!v.scrollboxSize()&&"absolute"===o.position,a=(s||i)&&"border-box"===A.css(e,"boxSizing",!1,o),c=i?tt(e,t,i,a,o):0;return a&&s&&(c-=Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-parseFloat(o[t])-tt(e,t,"border",!1,o)-.5)),c&&(n=ne.exec(r))&&"px"!==(n[3]||"px")&&(e.style[t]=r,r=A.css(e,t)),et(0,r,c)}}})),A.cssHooks.marginLeft=Ke(v.reliableMarginLeft,(function(e,t){if(t)return(parseFloat(ze(e,"marginLeft"))||e.getBoundingClientRect().left-qe(e,{marginLeft:0},(function(){return e.getBoundingClientRect().left})))+"px"})),A.each({margin:"",padding:"",border:"Width"},(function(e,t){A.cssHooks[e+t]={expand:function(r){for(var i=0,n={},o="string"==typeof r?r.split(" "):[r];i<4;i++)n[e+oe[i]+t]=o[i]||o[i-2]||o[0];return n}},"margin"!==e&&(A.cssHooks[e+t].set=et)})),A.fn.extend({css:function(e,t){return K(this,(function(e,t,r){var i,n,o={},s=0;if(Array.isArray(t)){for(i=We(e),n=t.length;s1)}}),A.Tween=it,it.prototype={constructor:it,init:function(e,t,r,i,n,o){this.elem=e,this.prop=r,this.easing=n||A.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=i,this.unit=o||(A.cssNumber[r]?"":"px")},cur:function(){var e=it.propHooks[this.prop];return e&&e.get?e.get(this):it.propHooks._default.get(this)},run:function(e){var t,r=it.propHooks[this.prop];return this.options.duration?this.pos=t=A.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),r&&r.set?r.set(this):it.propHooks._default.set(this),this}},it.prototype.init.prototype=it.prototype,it.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=A.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){A.fx.step[e.prop]?A.fx.step[e.prop](e):1!==e.elem.nodeType||!A.cssHooks[e.prop]&&null==e.elem.style[Ye(e.prop)]?e.elem[e.prop]=e.now:A.style(e.elem,e.prop,e.now+e.unit)}}},it.propHooks.scrollTop=it.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},A.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},A.fx=it.prototype.init,A.fx.step={};var nt,ot,st=/^(?:toggle|show|hide)$/,at=/queueHooks$/;function ct(){ot&&(!1===m.hidden&&i.requestAnimationFrame?i.requestAnimationFrame(ct):i.setTimeout(ct,A.fx.interval),A.fx.tick())}function lt(){return i.setTimeout((function(){nt=void 0})),nt=Date.now()}function ut(e,t){var r,i=0,n={height:e};for(t=t?1:0;i<4;i+=2-t)n["margin"+(r=oe[i])]=n["padding"+r]=e;return t&&(n.opacity=n.width=e),n}function ht(e,t,r){for(var i,n=(ft.tweeners[t]||[]).concat(ft.tweeners["*"]),o=0,s=n.length;o1)},removeAttr:function(e){return this.each((function(){A.removeAttr(this,e)}))}}),A.extend({attr:function(e,t,r){var i,n,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===e.getAttribute?A.prop(e,t,r):(1===o&&A.isXMLDoc(e)||(n=A.attrHooks[t.toLowerCase()]||(A.expr.match.bool.test(t)?dt:void 0)),void 0!==r?null===r?void A.removeAttr(e,t):n&&"set"in n&&void 0!==(i=n.set(e,r,t))?i:(e.setAttribute(t,r+""),r):n&&"get"in n&&null!==(i=n.get(e,t))?i:null==(i=A.find.attr(e,t))?void 0:i)},attrHooks:{type:{set:function(e,t){if(!v.radioValue&&"radio"===t&&R(e,"input")){var r=e.value;return e.setAttribute("type",t),r&&(e.value=r),t}}}},removeAttr:function(e,t){var r,i=0,n=t&&t.match(j);if(n&&1===e.nodeType)for(;r=n[i++];)e.removeAttribute(r)}}),dt={set:function(e,t,r){return!1===t?A.removeAttr(e,r):e.setAttribute(r,r),r}},A.each(A.expr.match.bool.source.match(/\w+/g),(function(e,t){var r=pt[t]||A.find.attr;pt[t]=function(e,t,i){var n,o,s=t.toLowerCase();return i||(o=pt[s],pt[s]=n,n=null!=r(e,t,i)?s:null,pt[s]=o),n}}));var _t=/^(?:input|select|textarea|button)$/i,vt=/^(?:a|area)$/i;function gt(e){return(e.match(j)||[]).join(" ")}function yt(e){return e.getAttribute&&e.getAttribute("class")||""}function mt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(j)||[]}A.fn.extend({prop:function(e,t){return K(this,A.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each((function(){delete this[A.propFix[e]||e]}))}}),A.extend({prop:function(e,t,r){var i,n,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&A.isXMLDoc(e)||(t=A.propFix[t]||t,n=A.propHooks[t]),void 0!==r?n&&"set"in n&&void 0!==(i=n.set(e,r,t))?i:e[t]=r:n&&"get"in n&&null!==(i=n.get(e,t))?i:e[t]},propHooks:{tabIndex:{get:function(e){var t=A.find.attr(e,"tabindex");return t?parseInt(t,10):_t.test(e.nodeName)||vt.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),v.optSelected||(A.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),A.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],(function(){A.propFix[this.toLowerCase()]=this})),A.fn.extend({addClass:function(e){var t,r,i,n,o,s,a,c=0;if(g(e))return this.each((function(t){A(this).addClass(e.call(this,t,yt(this)))}));if((t=mt(e)).length)for(;r=this[c++];)if(n=yt(r),i=1===r.nodeType&&" "+gt(n)+" "){for(s=0;o=t[s++];)i.indexOf(" "+o+" ")<0&&(i+=o+" ");n!==(a=gt(i))&&r.setAttribute("class",a)}return this},removeClass:function(e){var t,r,i,n,o,s,a,c=0;if(g(e))return this.each((function(t){A(this).removeClass(e.call(this,t,yt(this)))}));if(!arguments.length)return this.attr("class","");if((t=mt(e)).length)for(;r=this[c++];)if(n=yt(r),i=1===r.nodeType&&" "+gt(n)+" "){for(s=0;o=t[s++];)for(;i.indexOf(" "+o+" ")>-1;)i=i.replace(" "+o+" "," ");n!==(a=gt(i))&&r.setAttribute("class",a)}return this},toggleClass:function(e,t){var r=typeof e,i="string"===r||Array.isArray(e);return"boolean"==typeof t&&i?t?this.addClass(e):this.removeClass(e):g(e)?this.each((function(r){A(this).toggleClass(e.call(this,r,yt(this),t),t)})):this.each((function(){var t,n,o,s;if(i)for(n=0,o=A(this),s=mt(e);t=s[n++];)o.hasClass(t)?o.removeClass(t):o.addClass(t);else void 0!==e&&"boolean"!==r||((t=yt(this))&&Z.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||!1===e?"":Z.get(this,"__className__")||""))}))},hasClass:function(e){var t,r,i=0;for(t=" "+e+" ";r=this[i++];)if(1===r.nodeType&&(" "+gt(yt(r))+" ").indexOf(t)>-1)return!0;return!1}});var bt=/\r/g;A.fn.extend({val:function(e){var t,r,i,n=this[0];return arguments.length?(i=g(e),this.each((function(r){var n;1===this.nodeType&&(null==(n=i?e.call(this,r,A(this).val()):e)?n="":"number"==typeof n?n+="":Array.isArray(n)&&(n=A.map(n,(function(e){return null==e?"":e+""}))),(t=A.valHooks[this.type]||A.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,n,"value")||(this.value=n))}))):n?(t=A.valHooks[n.type]||A.valHooks[n.nodeName.toLowerCase()])&&"get"in t&&void 0!==(r=t.get(n,"value"))?r:"string"==typeof(r=n.value)?r.replace(bt,""):null==r?"":r:void 0}}),A.extend({valHooks:{option:{get:function(e){var t=A.find.attr(e,"value");return null!=t?t:gt(A.text(e))}},select:{get:function(e){var t,r,i,n=e.options,o=e.selectedIndex,s="select-one"===e.type,a=s?null:[],c=s?o+1:n.length;for(i=o<0?c:s?o:0;i-1)&&(r=!0);return r||(e.selectedIndex=-1),o}}}}),A.each(["radio","checkbox"],(function(){A.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=A.inArray(A(e).val(),t)>-1}},v.checkOn||(A.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})})),v.focusin="onfocusin"in i;var St=/^(?:focusinfocus|focusoutblur)$/,Ct=function(e){e.stopPropagation()};A.extend(A.event,{trigger:function(e,t,r,n){var o,s,a,c,l,u,h,f,p=[r||m],_=d.call(e,"type")?e.type:e,v=d.call(e,"namespace")?e.namespace.split("."):[];if(s=f=a=r=r||m,3!==r.nodeType&&8!==r.nodeType&&!St.test(_+A.event.triggered)&&(_.indexOf(".")>-1&&(v=_.split("."),_=v.shift(),v.sort()),l=_.indexOf(":")<0&&"on"+_,(e=e[A.expando]?e:new A.Event(_,"object"==typeof e&&e)).isTrigger=n?2:3,e.namespace=v.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+v.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=r),t=null==t?[e]:A.makeArray(t,[e]),h=A.event.special[_]||{},n||!h.trigger||!1!==h.trigger.apply(r,t))){if(!n&&!h.noBubble&&!y(r)){for(c=h.delegateType||_,St.test(c+_)||(s=s.parentNode);s;s=s.parentNode)p.push(s),a=s;a===(r.ownerDocument||m)&&p.push(a.defaultView||a.parentWindow||i)}for(o=0;(s=p[o++])&&!e.isPropagationStopped();)f=s,e.type=o>1?c:h.bindType||_,(u=(Z.get(s,"events")||Object.create(null))[e.type]&&Z.get(s,"handle"))&&u.apply(s,t),(u=l&&s[l])&&u.apply&&$(s)&&(e.result=u.apply(s,t),!1===e.result&&e.preventDefault());return e.type=_,n||e.isDefaultPrevented()||h._default&&!1!==h._default.apply(p.pop(),t)||!$(r)||l&&g(r[_])&&!y(r)&&((a=r[l])&&(r[l]=null),A.event.triggered=_,e.isPropagationStopped()&&f.addEventListener(_,Ct),r[_](),e.isPropagationStopped()&&f.removeEventListener(_,Ct),A.event.triggered=void 0,a&&(r[l]=a)),e.result}},simulate:function(e,t,r){var i=A.extend(new A.Event,r,{type:e,isSimulated:!0});A.event.trigger(i,null,t)}}),A.fn.extend({trigger:function(e,t){return this.each((function(){A.event.trigger(e,t,this)}))},triggerHandler:function(e,t){var r=this[0];if(r)return A.event.trigger(e,t,r,!0)}}),v.focusin||A.each({focus:"focusin",blur:"focusout"},(function(e,t){var r=function(e){A.event.simulate(t,e.target,A.event.fix(e))};A.event.special[t]={setup:function(){var i=this.ownerDocument||this.document||this,n=Z.access(i,t);n||i.addEventListener(e,r,!0),Z.access(i,t,(n||0)+1)},teardown:function(){var i=this.ownerDocument||this.document||this,n=Z.access(i,t)-1;n?Z.access(i,t,n):(i.removeEventListener(e,r,!0),Z.remove(i,t))}}}));var wt=i.location,At={guid:Date.now()},xt=/\?/;A.parseXML=function(e){var t,r;if(!e||"string"!=typeof e)return null;try{t=(new i.DOMParser).parseFromString(e,"text/xml")}catch(e){}return r=t&&t.getElementsByTagName("parsererror")[0],t&&!r||A.error("Invalid XML: "+(r?A.map(r.childNodes,(function(e){return e.textContent})).join("\n"):e)),t};var Et=/\[\]$/,Lt=/\r?\n/g,kt=/^(?:submit|button|image|reset|file)$/i,Tt=/^(?:input|select|textarea|keygen)/i;function Rt(e,t,r,i){var n;if(Array.isArray(t))A.each(t,(function(t,n){r||Et.test(e)?i(e,n):Rt(e+"["+("object"==typeof n&&null!=n?t:"")+"]",n,r,i)}));else if(r||"object"!==C(t))i(e,t);else for(n in t)Rt(e+"["+n+"]",t[n],r,i)}A.param=function(e,t){var r,i=[],n=function(e,t){var r=g(t)?t():t;i[i.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==r?"":r)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!A.isPlainObject(e))A.each(e,(function(){n(this.name,this.value)}));else for(r in e)Rt(r,e[r],t,n);return i.join("&")},A.fn.extend({serialize:function(){return A.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var e=A.prop(this,"elements");return e?A.makeArray(e):this})).filter((function(){var e=this.type;return this.name&&!A(this).is(":disabled")&&Tt.test(this.nodeName)&&!kt.test(e)&&(this.checked||!ve.test(e))})).map((function(e,t){var r=A(this).val();return null==r?null:Array.isArray(r)?A.map(r,(function(e){return{name:t.name,value:e.replace(Lt,"\r\n")}})):{name:t.name,value:r.replace(Lt,"\r\n")}})).get()}});var Dt=/%20/g,Ot=/#.*$/,Pt=/([?&])_=[^&]*/,It=/^(.*?):[ \t]*([^\r\n]*)$/gm,Mt=/^(?:GET|HEAD)$/,Ht=/^\/\//,Bt={},jt={},Ft="*/".concat("*"),Nt=m.createElement("a");function Wt(e){return function(t,r){"string"!=typeof t&&(r=t,t="*");var i,n=0,o=t.toLowerCase().match(j)||[];if(g(r))for(;i=o[n++];)"+"===i[0]?(i=i.slice(1)||"*",(e[i]=e[i]||[]).unshift(r)):(e[i]=e[i]||[]).push(r)}}function qt(e,t,r,i){var n={},o=e===jt;function s(a){var c;return n[a]=!0,A.each(e[a]||[],(function(e,a){var l=a(t,r,i);return"string"!=typeof l||o||n[l]?o?!(c=l):void 0:(t.dataTypes.unshift(l),s(l),!1)})),c}return s(t.dataTypes[0])||!n["*"]&&s("*")}function Ut(e,t){var r,i,n=A.ajaxSettings.flatOptions||{};for(r in t)void 0!==t[r]&&((n[r]?e:i||(i={}))[r]=t[r]);return i&&A.extend(!0,e,i),e}Nt.href=wt.href,A.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:wt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(wt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Ft,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":A.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Ut(Ut(e,A.ajaxSettings),t):Ut(A.ajaxSettings,e)},ajaxPrefilter:Wt(Bt),ajaxTransport:Wt(jt),ajax:function(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var r,n,o,s,a,c,l,u,h,f,d=A.ajaxSetup({},t),p=d.context||d,_=d.context&&(p.nodeType||p.jquery)?A(p):A.event,v=A.Deferred(),g=A.Callbacks("once memory"),y=d.statusCode||{},b={},S={},C="canceled",w={readyState:0,getResponseHeader:function(e){var t;if(l){if(!s)for(s={};t=It.exec(o);)s[t[1].toLowerCase()+" "]=(s[t[1].toLowerCase()+" "]||[]).concat(t[2]);t=s[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return l?o:null},setRequestHeader:function(e,t){return null==l&&(e=S[e.toLowerCase()]=S[e.toLowerCase()]||e,b[e]=t),this},overrideMimeType:function(e){return null==l&&(d.mimeType=e),this},statusCode:function(e){var t;if(e)if(l)w.always(e[w.status]);else for(t in e)y[t]=[y[t],e[t]];return this},abort:function(e){var t=e||C;return r&&r.abort(t),x(0,t),this}};if(v.promise(w),d.url=((e||d.url||wt.href)+"").replace(Ht,wt.protocol+"//"),d.type=t.method||t.type||d.method||d.type,d.dataTypes=(d.dataType||"*").toLowerCase().match(j)||[""],null==d.crossDomain){c=m.createElement("a");try{c.href=d.url,c.href=c.href,d.crossDomain=Nt.protocol+"//"+Nt.host!=c.protocol+"//"+c.host}catch(e){d.crossDomain=!0}}if(d.data&&d.processData&&"string"!=typeof d.data&&(d.data=A.param(d.data,d.traditional)),qt(Bt,d,t,w),l)return w;for(h in(u=A.event&&d.global)&&0==A.active++&&A.event.trigger("ajaxStart"),d.type=d.type.toUpperCase(),d.hasContent=!Mt.test(d.type),n=d.url.replace(Ot,""),d.hasContent?d.data&&d.processData&&0===(d.contentType||"").indexOf("application/x-www-form-urlencoded")&&(d.data=d.data.replace(Dt,"+")):(f=d.url.slice(n.length),d.data&&(d.processData||"string"==typeof d.data)&&(n+=(xt.test(n)?"&":"?")+d.data,delete d.data),!1===d.cache&&(n=n.replace(Pt,"$1"),f=(xt.test(n)?"&":"?")+"_="+At.guid+++f),d.url=n+f),d.ifModified&&(A.lastModified[n]&&w.setRequestHeader("If-Modified-Since",A.lastModified[n]),A.etag[n]&&w.setRequestHeader("If-None-Match",A.etag[n])),(d.data&&d.hasContent&&!1!==d.contentType||t.contentType)&&w.setRequestHeader("Content-Type",d.contentType),w.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+("*"!==d.dataTypes[0]?", "+Ft+"; q=0.01":""):d.accepts["*"]),d.headers)w.setRequestHeader(h,d.headers[h]);if(d.beforeSend&&(!1===d.beforeSend.call(p,w,d)||l))return w.abort();if(C="abort",g.add(d.complete),w.done(d.success),w.fail(d.error),r=qt(jt,d,t,w)){if(w.readyState=1,u&&_.trigger("ajaxSend",[w,d]),l)return w;d.async&&d.timeout>0&&(a=i.setTimeout((function(){w.abort("timeout")}),d.timeout));try{l=!1,r.send(b,x)}catch(e){if(l)throw e;x(-1,e)}}else x(-1,"No Transport");function x(e,t,s,c){var h,f,m,b,S,C=t;l||(l=!0,a&&i.clearTimeout(a),r=void 0,o=c||"",w.readyState=e>0?4:0,h=e>=200&&e<300||304===e,s&&(b=function(e,t,r){for(var i,n,o,s,a=e.contents,c=e.dataTypes;"*"===c[0];)c.shift(),void 0===i&&(i=e.mimeType||t.getResponseHeader("Content-Type"));if(i)for(n in a)if(a[n]&&a[n].test(i)){c.unshift(n);break}if(c[0]in r)o=c[0];else{for(n in r){if(!c[0]||e.converters[n+" "+c[0]]){o=n;break}s||(s=n)}o=o||s}if(o)return o!==c[0]&&c.unshift(o),r[o]}(d,w,s)),!h&&A.inArray("script",d.dataTypes)>-1&&A.inArray("json",d.dataTypes)<0&&(d.converters["text script"]=function(){}),b=function(e,t,r,i){var n,o,s,a,c,l={},u=e.dataTypes.slice();if(u[1])for(s in e.converters)l[s.toLowerCase()]=e.converters[s];for(o=u.shift();o;)if(e.responseFields[o]&&(r[e.responseFields[o]]=t),!c&&i&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),c=o,o=u.shift())if("*"===o)o=c;else if("*"!==c&&c!==o){if(!(s=l[c+" "+o]||l["* "+o]))for(n in l)if((a=n.split(" "))[1]===o&&(s=l[c+" "+a[0]]||l["* "+a[0]])){!0===s?s=l[n]:!0!==l[n]&&(o=a[0],u.unshift(a[1]));break}if(!0!==s)if(s&&e.throws)t=s(t);else try{t=s(t)}catch(e){return{state:"parsererror",error:s?e:"No conversion from "+c+" to "+o}}}return{state:"success",data:t}}(d,b,w,h),h?(d.ifModified&&((S=w.getResponseHeader("Last-Modified"))&&(A.lastModified[n]=S),(S=w.getResponseHeader("etag"))&&(A.etag[n]=S)),204===e||"HEAD"===d.type?C="nocontent":304===e?C="notmodified":(C=b.state,f=b.data,h=!(m=b.error))):(m=C,!e&&C||(C="error",e<0&&(e=0))),w.status=e,w.statusText=(t||C)+"",h?v.resolveWith(p,[f,C,w]):v.rejectWith(p,[w,C,m]),w.statusCode(y),y=void 0,u&&_.trigger(h?"ajaxSuccess":"ajaxError",[w,d,h?f:m]),g.fireWith(p,[w,C]),u&&(_.trigger("ajaxComplete",[w,d]),--A.active||A.event.trigger("ajaxStop")))}return w},getJSON:function(e,t,r){return A.get(e,t,r,"json")},getScript:function(e,t){return A.get(e,void 0,t,"script")}}),A.each(["get","post"],(function(e,t){A[t]=function(e,r,i,n){return g(r)&&(n=n||i,i=r,r=void 0),A.ajax(A.extend({url:e,type:t,dataType:n,data:r,success:i},A.isPlainObject(e)&&e))}})),A.ajaxPrefilter((function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")})),A._evalUrl=function(e,t,r){return A.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){A.globalEval(e,t,r)}})},A.fn.extend({wrapAll:function(e){var t;return this[0]&&(g(e)&&(e=e.call(this[0])),t=A(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map((function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e})).append(this)),this},wrapInner:function(e){return g(e)?this.each((function(t){A(this).wrapInner(e.call(this,t))})):this.each((function(){var t=A(this),r=t.contents();r.length?r.wrapAll(e):t.append(e)}))},wrap:function(e){var t=g(e);return this.each((function(r){A(this).wrapAll(t?e.call(this,r):e)}))},unwrap:function(e){return this.parent(e).not("body").each((function(){A(this).replaceWith(this.childNodes)})),this}}),A.expr.pseudos.hidden=function(e){return!A.expr.pseudos.visible(e)},A.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},A.ajaxSettings.xhr=function(){try{return new i.XMLHttpRequest}catch(e){}};var zt={0:200,1223:204},Kt=A.ajaxSettings.xhr();v.cors=!!Kt&&"withCredentials"in Kt,v.ajax=Kt=!!Kt,A.ajaxTransport((function(e){var t,r;if(v.cors||Kt&&!e.crossDomain)return{send:function(n,o){var s,a=e.xhr();if(a.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(s in e.xhrFields)a[s]=e.xhrFields[s];for(s in e.mimeType&&a.overrideMimeType&&a.overrideMimeType(e.mimeType),e.crossDomain||n["X-Requested-With"]||(n["X-Requested-With"]="XMLHttpRequest"),n)a.setRequestHeader(s,n[s]);t=function(e){return function(){t&&(t=r=a.onload=a.onerror=a.onabort=a.ontimeout=a.onreadystatechange=null,"abort"===e?a.abort():"error"===e?"number"!=typeof a.status?o(0,"error"):o(a.status,a.statusText):o(zt[a.status]||a.status,a.statusText,"text"!==(a.responseType||"text")||"string"!=typeof a.responseText?{binary:a.response}:{text:a.responseText},a.getAllResponseHeaders()))}},a.onload=t(),r=a.onerror=a.ontimeout=t("error"),void 0!==a.onabort?a.onabort=r:a.onreadystatechange=function(){4===a.readyState&&i.setTimeout((function(){t&&r()}))},t=t("abort");try{a.send(e.hasContent&&e.data||null)}catch(e){if(t)throw e}},abort:function(){t&&t()}}})),A.ajaxPrefilter((function(e){e.crossDomain&&(e.contents.script=!1)})),A.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return A.globalEval(e),e}}}),A.ajaxPrefilter("script",(function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")})),A.ajaxTransport("script",(function(e){var t,r;if(e.crossDomain||e.scriptAttrs)return{send:function(i,n){t=A(" ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/nbgitpuller/templates/status.html0000644000175100001710000000345000000000000023401 0ustar00runnerdocker00000000000000{% extends "page.html" %} {% block params %} {{super()}} data-base-url="{{ base_url | urlencode }}" data-repo="{{ repo | urlencode }}" data-path="{{ path | urlencode }}" {% if branch %}data-branch="{{ branch | urlencode }}"{% endif %} {% if depth %}data-depth="{{ depth | urlencode }}"{% endif %} data-targetpath="{{ targetpath | urlencode }}" {% endblock %} {% block site %}
Click to see more details
{% endblock %} {% block script %} {{super()}} {% endblock %} {% block stylesheet %} {{super()}} {% endblock %} ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/nbgitpuller/version.py0000644000175100001710000000011200000000000021221 0ustar00runnerdocker00000000000000""""The nbgitpuller PyPI package SemVer version.""" __version__ = '1.0.2' ././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5190263 nbgitpuller-1.0.2/nbgitpuller.egg-info/0000755000175100001710000000000000000000000020662 5ustar00runnerdocker00000000000000././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625883.0 nbgitpuller-1.0.2/nbgitpuller.egg-info/PKG-INFO0000644000175100001710000000423100000000000021757 0ustar00runnerdocker00000000000000Metadata-Version: 2.1 Name: nbgitpuller Version: 1.0.2 Summary: Notebook Extension to do one-way synchronization of git repositories Home-page: https://github.com/jupyterhub/nbgitpuller Author: Peter Veerman, YuviPanda Author-email: peterkangveerman@gmail.com License: 3-clause BSD Platform: any Classifier: Development Status :: 4 - Beta Classifier: License :: OSI Approved :: BSD License Classifier: Operating System :: POSIX Classifier: Operating System :: MacOS Classifier: Operating System :: Unix Classifier: Programming Language :: Python :: 3 Classifier: Topic :: Software Development :: Libraries :: Python Modules Description-Content-Type: text/markdown License-File: LICENSE # [nbgitpuller](https://github.com/jupyterhub/nbgitpuller) [![GitHub Workflow Status - Test](https://img.shields.io/github/workflow/status/jupyterhub/nbgitpuller/Tests?logo=github&label=tests)](https://github.com/jupyterhub/nbgitpuller/actions) [![CircleCI build status](https://img.shields.io/circleci/build/github/jupyterhub/nbgitpuller?logo=circleci&label=docs)](https://circleci.com/gh/jupyterhub/nbgitpuller) [![](https://img.shields.io/pypi/v/nbgitpuller.svg?logo=pypi)](https://pypi.python.org/pypi/nbgitpuller) [![GitHub](https://img.shields.io/badge/issue_tracking-github-blue?logo=github)](https://github.com/jupyterhub/nbgitpuller/issues) [![Discourse](https://img.shields.io/badge/help_forum-discourse-blue?logo=discourse)](https://discourse.jupyter.org/c/jupyterhub) [![Gitter](https://img.shields.io/badge/social_chat-gitter-blue?logo=gitter)](https://gitter.im/jupyterhub/jupyterhub) `nbgitpuller` lets you distribute content in a git repository to your students by having them click a simple link. [Automatic merging](https://jupyterhub.github.io/nbgitpuller/topic/automatic-merging.html) ensures that your students are never exposed to `git` directly. It is primarily used with a JupyterHub, but can also work on students' local computers. See [the documentation](https://jupyterhub.github.io/nbgitpuller) for more information. ## Installation ```shell pip install nbgitpuller ``` ## Example ![](https://raw.githubusercontent.com/jupyterhub/nbgitpuller/v0.8.0/docs/_static/nbpuller.gif) ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625883.0 nbgitpuller-1.0.2/nbgitpuller.egg-info/SOURCES.txt0000644000175100001710000000140000000000000022541 0ustar00runnerdocker00000000000000CHANGELOG.md LICENSE MANIFEST.in README.md RELEASE.md package.json pyproject.toml setup.cfg setup.py nbgitpuller/__init__.py nbgitpuller/handlers.py nbgitpuller/pull.py nbgitpuller/version.py nbgitpuller.egg-info/PKG-INFO nbgitpuller.egg-info/SOURCES.txt nbgitpuller.egg-info/dependency_links.txt nbgitpuller.egg-info/entry_points.txt nbgitpuller.egg-info/not-zip-safe nbgitpuller.egg-info/requires.txt nbgitpuller.egg-info/top_level.txt nbgitpuller/etc/jupyter_notebook_config.d/nbgitpuller.json nbgitpuller/etc/jupyter_server_config.d/nbgitpuller.json nbgitpuller/static/dist/bundle.js nbgitpuller/static/dist/bundle.js.LICENSE.txt nbgitpuller/static/dist/bundle.js.map nbgitpuller/static/js/index.js nbgitpuller/templates/page.html nbgitpuller/templates/status.html././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625883.0 nbgitpuller-1.0.2/nbgitpuller.egg-info/dependency_links.txt0000644000175100001710000000000100000000000024730 0ustar00runnerdocker00000000000000 ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625883.0 nbgitpuller-1.0.2/nbgitpuller.egg-info/entry_points.txt0000644000175100001710000000006500000000000024161 0ustar00runnerdocker00000000000000[console_scripts] gitpuller = nbgitpuller.pull:main ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625870.0 nbgitpuller-1.0.2/nbgitpuller.egg-info/not-zip-safe0000644000175100001710000000000100000000000023110 0ustar00runnerdocker00000000000000 ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625883.0 nbgitpuller-1.0.2/nbgitpuller.egg-info/requires.txt0000644000175100001710000000005700000000000023264 0ustar00runnerdocker00000000000000notebook>=5.5.0 jupyter_server>=1.10.1 tornado ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625883.0 nbgitpuller-1.0.2/nbgitpuller.egg-info/top_level.txt0000644000175100001710000000001400000000000023407 0ustar00runnerdocker00000000000000nbgitpuller ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/package.json0000644000175100001710000000066300000000000017134 0ustar00runnerdocker00000000000000{ "description": "Dependencies to build nbgitpuller/static/dist/bundle.js from nbgitpuller/static/js/index.js with webpack.", "devDependencies": { "jquery": "^3.6.0", "webpack": "^5.45.1", "webpack-cli": "^4.7.2", "xterm": "^4.13.0", "xterm-addon-fit": "^0.5.0", "css-loader": "^6.2.0", "style-loader": "^3.2.1" }, "scripts": { "webpack": "webpack", "webpack:watch": "webpack --watch" } } ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/pyproject.toml0000644000175100001710000000017600000000000017561 0ustar00runnerdocker00000000000000[build-system] requires = [ "build", "jupyter-packaging>=0.10", "setuptools", ] build-backend = "setuptools.build_meta" ././@PaxHeader0000000000000000000000000000003400000000000011452 xustar000000000000000028 mtime=1630625883.5230262 nbgitpuller-1.0.2/setup.cfg0000644000175100001710000000007500000000000016464 0ustar00runnerdocker00000000000000[wheel] universal = 1 [egg_info] tag_build = tag_date = 0 ././@PaxHeader0000000000000000000000000000002600000000000011453 xustar000000000000000022 mtime=1630625862.0 nbgitpuller-1.0.2/setup.py0000644000175100001710000000420500000000000016354 0ustar00runnerdocker00000000000000from jupyter_packaging import wrap_installers, npm_builder from setuptools import find_packages, setup from distutils.util import convert_path import os.path HERE = os.path.abspath(os.path.dirname(__file__)) # Representative files that should exist after a successful build jstargets = [ os.path.join(HERE, "nbgitpuller", "static", "dist", "bundle.js"), ] # https://github.com/jupyter/jupyter-packaging/blob/0.10.4/README.md#as-a-build-requirement jsdeps = npm_builder(build_cmd="webpack") cmdclass = wrap_installers( pre_develop=jsdeps, pre_dist=jsdeps, ensured_targets=jstargets, skip_if_exists=jstargets) # Imports __version__, reference: https://stackoverflow.com/a/24517154/2220152 ns = {} ver_path = convert_path('nbgitpuller/version.py') with open(ver_path) as ver_file: exec(ver_file.read(), ns) __version__ = ns['__version__'] setup( name='nbgitpuller', version=__version__, url='https://github.com/jupyterhub/nbgitpuller', license='3-clause BSD', author='Peter Veerman, YuviPanda', author_email='peterkangveerman@gmail.com', cmdclass=cmdclass, description='Notebook Extension to do one-way synchronization of git repositories', long_description=open('README.md').read(), long_description_content_type='text/markdown', packages=find_packages(), include_package_data=True, platforms='any', install_requires=['notebook>=5.5.0', 'jupyter_server>=1.10.1', 'tornado'], data_files=[ ('etc/jupyter/jupyter_server_config.d', ['nbgitpuller/etc/jupyter_server_config.d/nbgitpuller.json']), ('etc/jupyter/jupyter_notebook_config.d', ['nbgitpuller/etc/jupyter_notebook_config.d/nbgitpuller.json']) ], zip_safe=False, entry_points={ 'console_scripts': [ 'gitpuller = nbgitpuller.pull:main', ], }, classifiers=[ 'Development Status :: 4 - Beta', 'License :: OSI Approved :: BSD License', 'Operating System :: POSIX', 'Operating System :: MacOS', 'Operating System :: Unix', 'Programming Language :: Python :: 3', 'Topic :: Software Development :: Libraries :: Python Modules', ] )