Mercurial > repos > fubar > mashmap
changeset 1:0183cad9d13b draft
planemo upload
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/abslen_bed/abslen_bed.python.txt Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,14 @@ +#raw +import sys +inp = [] +for line in sys.stdin: + if line.strip() > '': + ls = line.split() + if len(ls) > 2: + x = abs(int(ls[2]) - int(ls[1])) + ls.append((str(x))) + inp.append('\t'.join(ls)) + else: + break +sys.stdout.write('\n'.join(inp)) +#end raw
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/abslen_bed/abslen_bed.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,56 @@ +<tool name="abslen_bed" id="abslen_bed" version="1" profile="22.05"> + <!--Source in git at: https://github.com/fubar2/galaxy_tf_overlay--> + <!--Created by toolfactory@galaxy.org at 10/12/2023 11:37:03 using the Galaxy Tool Factory.--> + <description>Returns a file of absolute values from differences</description> + <requirements> + <requirement type="package">python</requirement> + </requirements> + <version_command><![CDATA[echo "1"]]></version_command> + <command><![CDATA[python +'$runme' +< +$absin +> +$absout]]></command> + <configfiles> + <configfile name="runme"><![CDATA[#raw +import sys +inp = [] +for line in sys.stdin: + if line.strip() > '': + ls = line.split() + if len(ls) > 2: + x = abs(int(ls[2]) - int(ls[1])) + ls.append((str(x))) + inp.append('\t'.join(ls)) + else: + break +sys.stdout.write('\n'.join(inp)) +#end raw]]></configfile> + </configfiles> + <inputs> + <param name="absin" type="data" optional="false" label="absin" help="Input file to be converted using abs()" format="csfasta,txt,tabular" multiple="false"/> + </inputs> + <outputs> + <data name="absout" format="bed" hidden="false"/> + </outputs> + <tests> + <test> + <param name="absin" value="absin_sample"/> + <output name="absout" value="absout_sample"/> + </test> + </tests> + <help><![CDATA[ + **What it Does** + Takes absolute values on the input + + This tool is a temporary step to enable the Sanger TreeVal NF gap_finder workflow to be + translated into Galaxy + + See https://github.com/fubar2/treeval_gal/tree/main/gap_finder + ]]></help> + <citations> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/abslen_bed/test-data/absin_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,4 @@ +mm10_knownGene_uc008xda.1 900 959 +mm10_knownGene_uc008xda.1 1009 1038 +mm10_knownGene_uc008xda.1 1088 1166 +mm10_knownGene_uc008xda.1 1216 1252
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/abslen_bed/test-data/absout_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,4 @@ +mm10_knownGene_uc008xda.1 900 959 59 +mm10_knownGene_uc008xda.1 1009 1038 29 +mm10_knownGene_uc008xda.1 1088 1166 78 +mm10_knownGene_uc008xda.1 1216 1252 36 \ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/hictk/hictk.bash.txt Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1 @@ +hictk convert -f --output-fmt 'hic' '$incool' '$outhic'
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/hictk/hictk.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,70 @@ +<tool name="hictk" id="hictk" version="0.0.8" profile="22.05"> + <!--Source in git at: https://github.com/fubar2/galaxy_tf_overlay--> + <!--Created by toolfactory@galaxy.org at 08/02/2024 15:23:17 using the Galaxy Tool Factory.--> + <description>cool to hic binary</description> + <requirements> + <requirement version="0.0.8" type="package">hictk</requirement> + </requirements> + <version_command><![CDATA[echo "0.0.8"]]></version_command> + <command><![CDATA[bash '$runme']]></command> + <configfiles> + <configfile name="runme"><![CDATA[hictk convert -f --output-fmt 'hic' '$incool' '$outhic']]></configfile> + </configfiles> + <inputs> + <param name="incool" type="data" optional="false" label="cool hdf5 data to convert to hic binary" help="" format="cool,mcool,scool" multiple="false"/> + </inputs> + <outputs> + <data name="outhic" format="hic" label="hictk convert on $incool.element_identifier hic" hidden="false"/> + </outputs> + <tests> + <test> + <output name="outhic" value="outhic_sample" compare="sim_size" delta_frac="0.1"/> + <param name="incool" value="incool_sample"/> + </test> + </tests> + <help><![CDATA[ + This tool converts cool/mcool/scool format files into juicebox_hic binary files + + It uses https://github.com/paulsengroup/hictk + + Copyright (C) 2023 Roberto Rossini <roberros@uio.no> + + License: MIT + + **hictk** + + ---- + + hictk is a blazing fast toolkit to work with .hic and .cool files. + + This repository hosts `hictk`: a set of CLI tools to work with Cooler, as well as `libhictk`: the C++ library underlying `hictk`. + + Python bindings for `libhictk` are available at https://github.com/paulsengroup/hictkpy. + + hictk is capable of reading files in `.cool`, `.mcool`, `.scool` and `.juicebox_hic` format (including hic v9) as well as writing `.cool` and `.mcool` files. + + **Installing hictk** + + hictk is developed on Linux and tested on Linux, MacOS and Windows. + + hictk can be installed using containers, bioconda or directly from source. + Refer to https://hictk.readthedocs.io/en/latest/installation.html for more information. + + **Running hictk** + + hictk provides the following subcommands but this tool implements only *convert* + + Refer to https://hictk.readthedocs.io/en/latest/cli_reference.html for more details. + + ]]></help> + <citations> + <citation type="bibtex">@article{hictk, +author = {Roberto Rossini}, +year = {2023}, +url = {https://github.com/paulsengroup/hictk}, +title = {hictk: blazing fast toolkit to work with .hic and .cool files} +}</citation> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/local_tool_conf.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,14 @@ +<toolbox tool_path="./local_tools"> + <section id="localtools" name="Local tools"> + <tool file="abslen_bed/abslen_bed.xml"/> + <tool file="hictk/hictk.xml"/> + <tool file="jbrowse2/jbrowse2.xml"/> + <tool file="mashmap/mashmap.xml"/> + <tool file="planemo_lint/planemo_lint.xml"/> + <tool file="pyrev_pos_test/pyrev_pos_test.xml"/> + <tool file="seqtk/seqtk_telo.xml"/> + <tool file="tacrev/tacrev.xml"/> + <tool file="tf_apikey_mutate/tf_apikey_mutate.xml"/> + <tool file="toolfactory/toolfactory.xml"/> + </section> +</toolbox>
--- a/mashmap/.shed.yml Thu Feb 22 07:24:04 2024 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,6 +0,0 @@ -category: ToolFactory generated Tools -description: ToolFactory autogenerated tool -name: mashmap -owner: fubar2 -synopsis: Fast local alignment boundaries -type: unrestricted
--- a/mashmap/mashmap.xml Thu Feb 22 07:24:04 2024 +0000 +++ b/mashmap/mashmap.xml Thu Feb 22 10:48:01 2024 +0000 @@ -1,6 +1,6 @@ <tool name="mashmap" id="mashmap" version="3.1.3" profile="22.05"> <!--Source in git at: https://github.com/fubar2/galaxy_tf_overlay--> - <!--Created by toolfactory@galaxy.org at 22/02/2024 18:14:17 using the Galaxy Tool Factory.--> + <!--Created by toolfactory@galaxy.org at 22/02/2024 21:43:25 using the Galaxy Tool Factory.--> <description>Fast local alignment boundaries</description> <requirements> <requirement version="3.1.3" type="package">mashmap</requirement> @@ -16,19 +16,19 @@ --dense \ #end if #if len($reflist) == 1: - -r $reflist -q '$query' + -r '$reflist' -q '$query' #else rm -rf 'reflist' #for i, mash in enumerate($reflist): #if i == 0: - echo $mash > 'reflist' + echo '$mash' > 'reflist' #else: - echo $mash >> 'reflist' + echo '$mash' >> 'reflist' #end if #end for --rl 'reflist' -q '$query' #end if -cp 'mashmap.out' $mashout]]></configfile> +cp 'mashmap.out' '$mashout']]></configfile> </configfiles> <inputs> <param name="query" type="data" optional="false" label="Query sequences (as fasta) to mash against the references supplied below" help="" format="fasta" multiple="false"/>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/planemo_lint/planemo_lint.bash.txt Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,7 @@ +#raw +cp $1 foo.tar +tar -xvf foo.tar +TOOLNAME=`find . -name "*.xml"` +echo "$$$$$TOOLNAME = $TOOLNAME" > $2 +planemo lint $TOOLNAME >> $2 +#end raw
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/planemo_lint/planemo_lint.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,41 @@ +<tool name="planemo_lint" id="planemo_lint" version="0.75.20" profile="22.05"> + <!--Source in git at: https://github.com/fubar2/galaxy_tf_overlay--> + <!--Created by toolfactory@galaxy.org at 05/02/2024 14:19:29 using the Galaxy Tool Factory.--> + <description></description> + <requirements> + <requirement version="0.75.20" type="package">planemo</requirement> + </requirements> + <version_command><![CDATA[echo "0.75.20"]]></version_command> + <command><![CDATA[bash +'$runme' +$Toolshed_archive_to_be_linted +$lint_output]]></command> + <configfiles> + <configfile name="runme"><![CDATA[#raw +cp $1 foo.tar +tar -xvf foo.tar +TOOLNAME=`find . -name "*.xml"` +echo "$$$$$TOOLNAME = $TOOLNAME" > $2 +planemo lint $TOOLNAME >> $2 +#end raw]]></configfile> + </configfiles> + <inputs> + <param name="Toolshed_archive_to_be_linted" type="data" optional="false" label="Toolshed archive to be linted" help="" format="tgz" multiple="false"/> + </inputs> + <outputs> + <data name="lint_output" format="txt" label="lint_output" hidden="false"/> + </outputs> + <tests> + <test> + <output name="lint_output" value="lint_output_sample" compare="diff" lines_diff="5"/> + <param name="Toolshed_archive_to_be_linted" value="Toolshed_archive_to_be_linted_sample"/> + </test> + </tests> + <help><![CDATA[ + **What it Does** + ]]></help> + <citations> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/planemotest/planemotest.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,77 @@ +<tool name="planemotest" id="planemotest" version="0.01"> + <!--Source in git at: https://github.com/fubar2/galaxy--> + <!--Created by toolfactory@galaxy.org at 25/05/2023 01:04:53 using the Galaxy Tool Factory.--> + <description>Tests a ToolFactory archive containing a new tool</description> + <requirements> + <requirement version="0.75.18" type="package">planemo</requirement> + </requirements> + <stdio> + <exit_code range="1:" level="fatal"/> + </stdio> + <version_command><![CDATA[echo "0.01"]]></version_command> + <command><![CDATA[bash +$runme +$Toolshed_archive_to_be_tested +$test_output]]></command> + <configfiles> + <configfile name="runme"><![CDATA[#raw + +### script for ToolFactory toolshed archive test tool +mkdir testout +tar -xvf $1 +TOOLNAME=`find . -name "*.xml"` +FIXED=$(basename "$TOOLNAME" | cut -d. -f1) +REP=testout/"$FIXED"_planemo_test_report.html +planemo test --update_test_data --test_output $REP $TOOLNAME > STDOUT +cp $REP $2 + +#end raw]]></configfile> + </configfiles> + <inputs> + <param name="Toolshed_archive_to_be_tested" type="data" optional="false" label="Toolshed archive to be tested" help="" format="tgz" multiple="false"/> + </inputs> + <outputs> + <data name="test_output" format="html" label="test_output" hidden="false"/> + </outputs> + <tests> + <test> + <output name="test_output" value="test_output_sample" compare="diff" lines_diff="5"/> + <param name="Toolshed_archive_to_be_tested" value="Toolshed_archive_to_be_tested_sample"/> + </test> + </tests> + <help><![CDATA[ + +**What it Does** + +Tests a tool archive with Planemo + +Runs planemo test and returns a toolshed archive updated with test outputs and a Planemo test result. + +NOTE: First run takes 5+ minutes as Planemo is installed by Conda. +The second and subsequent runs don't have that startup time. + +Dogfood demonstration - this tool was generated with the ToolFactory and is included as a sample of what's possible and potentially useful. + +------ + + +Script:: + + ### script for ToolFactory toolshed archive test tool + mkdir testout + tar -xvf $1 + TOOLNAME=`find . -name "*.xml"` + FIXED=$(basename "$TOOLNAME" | cut -d. -f1) + LOG=testout/"$FIXED"_planemo_test_log.txt + REP=testout/"$FIXED"_planemo_test_report.html + echo "using $LOG and $REP" + echo "## Found toolname = $TOOLNAME" > $LOG + planemo test --update_test_data --test_output $REP $TOOLNAME >> $LOG + cp $REP $2 + +]]></help> + <citations> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/planemotest/test-data/test_output_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,291 @@ +<!DOCTYPE html> +<html lang="en"> + <head> + <meta charset="utf-8"> + <meta http-equiv="X-UA-Compatible" content="IE=edge"> + <meta name="viewport" content="width=device-width, initial-scale=1"> + <title>Test Results (powered by Planemo)</title> + + <!-- Bootstrap --> + <style>/*! + * Bootstrap v3.3.1 (http://getbootstrap.com) + * Copyright 2011-2014 Twitter, Inc. + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) + *//*! normalize.css v3.0.2 | MIT License | git.io/normalize */html{font-family:sans-serif;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{margin:.67em 0;font-size:2em}mark{color:#000;background:#ff0}small{font-size:80%}sub,sup{position:relative;font-size:75%;line-height:0;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{height:0;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{margin:0;font:inherit;color:inherit}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{padding:0;border:0}input{line-height:normal}input[type=checkbox],input[type=radio]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;-webkit-appearance:textfield}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}fieldset{padding:.35em .625em .75em;margin:0 2px;border:1px solid silver}legend{padding:0;border:0}textarea{overflow:auto}optgroup{font-weight:700}table{border-spacing:0;border-collapse:collapse}td,th{padding:0}/*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */@media print{*,:before,:after{color:#000!important;text-shadow:none!important;background:transparent!important;-webkit-box-shadow:none!important;box-shadow:none!important}a,a:visited{text-decoration:underline}a[href]:after{content:" (" attr(href) ")"}abbr[title]:after{content:" (" attr(title) ")"}a[href^="#"]:after,a[href^="javascript:"]:after{content:""}pre,blockquote{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}tr,img{page-break-inside:avoid}img{max-width:100%!important}p,h2,h3{orphans:3;widows:3}h2,h3{page-break-after:avoid}select{background:#fff!important}.navbar{display:none}.btn>.caret,.dropup>.btn>.caret{border-top-color:#000!important}.label{border:1px solid #000}.table{border-collapse:collapse!important}.table td,.table th{background-color:#fff!important}.table-bordered th,.table-bordered td{border:1px solid #ddd!important}}@font-face{font-family:'Glyphicons Halflings';src:url(../fonts/glyphicons-halflings-regular.eot);src:url(../fonts/glyphicons-halflings-regular.eot?#iefix) format('embedded-opentype'),url(../fonts/glyphicons-halflings-regular.woff) format('woff'),url(../fonts/glyphicons-halflings-regular.ttf) format('truetype'),url(../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular) format('svg')}.glyphicon{position:relative;top:1px;display:inline-block;font-family:'Glyphicons Halflings';font-style:normal;font-weight:400;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glyphicon-asterisk:before{content:"\2a"}.glyphicon-plus:before{content:"\2b"}.glyphicon-euro:before,.glyphicon-eur:before{content:"\20ac"}.glyphicon-minus:before{content:"\2212"}.glyphicon-cloud:before{content:"\2601"}.glyphicon-envelope:before{content:"\2709"}.glyphicon-pencil:before{content:"\270f"}.glyphicon-glass:before{content:"\e001"}.glyphicon-music:before{content:"\e002"}.glyphicon-search:before{content:"\e003"}.glyphicon-heart:before{content:"\e005"}.glyphicon-star:before{content:"\e006"}.glyphicon-star-empty:before{content:"\e007"}.glyphicon-user:before{content:"\e008"}.glyphicon-film:before{content:"\e009"}.glyphicon-th-large:before{content:"\e010"}.glyphicon-th:before{content:"\e011"}.glyphicon-th-list:before{content:"\e012"}.glyphicon-ok:before{content:"\e013"}.glyphicon-remove:before{content:"\e014"}.glyphicon-zoom-in:before{content:"\e015"}.glyphicon-zoom-out:before{content:"\e016"}.glyphicon-off:before{content:"\e017"}.glyphicon-signal:before{content:"\e018"}.glyphicon-cog:before{content:"\e019"}.glyphicon-trash:before{content:"\e020"}.glyphicon-home:before{content:"\e021"}.glyphicon-file:before{content:"\e022"}.glyphicon-time:before{content:"\e023"}.glyphicon-road:before{content:"\e024"}.glyphicon-download-alt:before{content:"\e025"}.glyphicon-download:before{content:"\e026"}.glyphicon-upload:before{content:"\e027"}.glyphicon-inbox:before{content:"\e028"}.glyphicon-play-circle:before{content:"\e029"}.glyphicon-repeat:before{content:"\e030"}.glyphicon-refresh:before{content:"\e031"}.glyphicon-list-alt:before{content:"\e032"}.glyphicon-lock:before{content:"\e033"}.glyphicon-flag:before{content:"\e034"}.glyphicon-headphones:before{content:"\e035"}.glyphicon-volume-off:before{content:"\e036"}.glyphicon-volume-down:before{content:"\e037"}.glyphicon-volume-up:before{content:"\e038"}.glyphicon-qrcode:before{content:"\e039"}.glyphicon-barcode:before{content:"\e040"}.glyphicon-tag:before{content:"\e041"}.glyphicon-tags:before{content:"\e042"}.glyphicon-book:before{content:"\e043"}.glyphicon-bookmark:before{content:"\e044"}.glyphicon-print:before{content:"\e045"}.glyphicon-camera:before{content:"\e046"}.glyphicon-font:before{content:"\e047"}.glyphicon-bold:before{content:"\e048"}.glyphicon-italic:before{content:"\e049"}.glyphicon-text-height:before{content:"\e050"}.glyphicon-text-width:before{content:"\e051"}.glyphicon-align-left:before{content:"\e052"}.glyphicon-align-center:before{content:"\e053"}.glyphicon-align-right:before{content:"\e054"}.glyphicon-align-justify:before{content:"\e055"}.glyphicon-list:before{content:"\e056"}.glyphicon-indent-left:before{content:"\e057"}.glyphicon-indent-right:before{content:"\e058"}.glyphicon-facetime-video:before{content:"\e059"}.glyphicon-picture:before{content:"\e060"}.glyphicon-map-marker:before{content:"\e062"}.glyphicon-adjust:before{content:"\e063"}.glyphicon-tint:before{content:"\e064"}.glyphicon-edit:before{content:"\e065"}.glyphicon-share:before{content:"\e066"}.glyphicon-check:before{content:"\e067"}.glyphicon-move:before{content:"\e068"}.glyphicon-step-backward:before{content:"\e069"}.glyphicon-fast-backward:before{content:"\e070"}.glyphicon-backward:before{content:"\e071"}.glyphicon-play:before{content:"\e072"}.glyphicon-pause:before{content:"\e073"}.glyphicon-stop:before{content:"\e074"}.glyphicon-forward:before{content:"\e075"}.glyphicon-fast-forward:before{content:"\e076"}.glyphicon-step-forward:before{content:"\e077"}.glyphicon-eject:before{content:"\e078"}.glyphicon-chevron-left:before{content:"\e079"}.glyphicon-chevron-right:before{content:"\e080"}.glyphicon-plus-sign:before{content:"\e081"}.glyphicon-minus-sign:before{content:"\e082"}.glyphicon-remove-sign:before{content:"\e083"}.glyphicon-ok-sign:before{content:"\e084"}.glyphicon-question-sign:before{content:"\e085"}.glyphicon-info-sign:before{content:"\e086"}.glyphicon-screenshot:before{content:"\e087"}.glyphicon-remove-circle:before{content:"\e088"}.glyphicon-ok-circle:before{content:"\e089"}.glyphicon-ban-circle:before{content:"\e090"}.glyphicon-arrow-left:before{content:"\e091"}.glyphicon-arrow-right:before{content:"\e092"}.glyphicon-arrow-up:before{content:"\e093"}.glyphicon-arrow-down:before{content:"\e094"}.glyphicon-share-alt:before{content:"\e095"}.glyphicon-resize-full:before{content:"\e096"}.glyphicon-resize-small:before{content:"\e097"}.glyphicon-exclamation-sign:before{content:"\e101"}.glyphicon-gift:before{content:"\e102"}.glyphicon-leaf:before{content:"\e103"}.glyphicon-fire:before{content:"\e104"}.glyphicon-eye-open:before{content:"\e105"}.glyphicon-eye-close:before{content:"\e106"}.glyphicon-warning-sign:before{content:"\e107"}.glyphicon-plane:before{content:"\e108"}.glyphicon-calendar:before{content:"\e109"}.glyphicon-random:before{content:"\e110"}.glyphicon-comment:before{content:"\e111"}.glyphicon-magnet:before{content:"\e112"}.glyphicon-chevron-up:before{content:"\e113"}.glyphicon-chevron-down:before{content:"\e114"}.glyphicon-retweet:before{content:"\e115"}.glyphicon-shopping-cart:before{content:"\e116"}.glyphicon-folder-close:before{content:"\e117"}.glyphicon-folder-open:before{content:"\e118"}.glyphicon-resize-vertical:before{content:"\e119"}.glyphicon-resize-horizontal:before{content:"\e120"}.glyphicon-hdd:before{content:"\e121"}.glyphicon-bullhorn:before{content:"\e122"}.glyphicon-bell:before{content:"\e123"}.glyphicon-certificate:before{content:"\e124"}.glyphicon-thumbs-up:before{content:"\e125"}.glyphicon-thumbs-down:before{content:"\e126"}.glyphicon-hand-right:before{content:"\e127"}.glyphicon-hand-left:before{content:"\e128"}.glyphicon-hand-up:before{content:"\e129"}.glyphicon-hand-down:before{content:"\e130"}.glyphicon-circle-arrow-right:before{content:"\e131"}.glyphicon-circle-arrow-left:before{content:"\e132"}.glyphicon-circle-arrow-up:before{content:"\e133"}.glyphicon-circle-arrow-down:before{content:"\e134"}.glyphicon-globe:before{content:"\e135"}.glyphicon-wrench:before{content:"\e136"}.glyphicon-tasks:before{content:"\e137"}.glyphicon-filter:before{content:"\e138"}.glyphicon-briefcase:before{content:"\e139"}.glyphicon-fullscreen:before{content:"\e140"}.glyphicon-dashboard:before{content:"\e141"}.glyphicon-paperclip:before{content:"\e142"}.glyphicon-heart-empty:before{content:"\e143"}.glyphicon-link:before{content:"\e144"}.glyphicon-phone:before{content:"\e145"}.glyphicon-pushpin:before{content:"\e146"}.glyphicon-usd:before{content:"\e148"}.glyphicon-gbp:before{content:"\e149"}.glyphicon-sort:before{content:"\e150"}.glyphicon-sort-by-alphabet:before{content:"\e151"}.glyphicon-sort-by-alphabet-alt:before{content:"\e152"}.glyphicon-sort-by-order:before{content:"\e153"}.glyphicon-sort-by-order-alt:before{content:"\e154"}.glyphicon-sort-by-attributes:before{content:"\e155"}.glyphicon-sort-by-attributes-alt:before{content:"\e156"}.glyphicon-unchecked:before{content:"\e157"}.glyphicon-expand:before{content:"\e158"}.glyphicon-collapse-down:before{content:"\e159"}.glyphicon-collapse-up:before{content:"\e160"}.glyphicon-log-in:before{content:"\e161"}.glyphicon-flash:before{content:"\e162"}.glyphicon-log-out:before{content:"\e163"}.glyphicon-new-window:before{content:"\e164"}.glyphicon-record:before{content:"\e165"}.glyphicon-save:before{content:"\e166"}.glyphicon-open:before{content:"\e167"}.glyphicon-saved:before{content:"\e168"}.glyphicon-import:before{content:"\e169"}.glyphicon-export:before{content:"\e170"}.glyphicon-send:before{content:"\e171"}.glyphicon-floppy-disk:before{content:"\e172"}.glyphicon-floppy-saved:before{content:"\e173"}.glyphicon-floppy-remove:before{content:"\e174"}.glyphicon-floppy-save:before{content:"\e175"}.glyphicon-floppy-open:before{content:"\e176"}.glyphicon-credit-card:before{content:"\e177"}.glyphicon-transfer:before{content:"\e178"}.glyphicon-cutlery:before{content:"\e179"}.glyphicon-header:before{content:"\e180"}.glyphicon-compressed:before{content:"\e181"}.glyphicon-earphone:before{content:"\e182"}.glyphicon-phone-alt:before{content:"\e183"}.glyphicon-tower:before{content:"\e184"}.glyphicon-stats:before{content:"\e185"}.glyphicon-sd-video:before{content:"\e186"}.glyphicon-hd-video:before{content:"\e187"}.glyphicon-subtitles:before{content:"\e188"}.glyphicon-sound-stereo:before{content:"\e189"}.glyphicon-sound-dolby:before{content:"\e190"}.glyphicon-sound-5-1:before{content:"\e191"}.glyphicon-sound-6-1:before{content:"\e192"}.glyphicon-sound-7-1:before{content:"\e193"}.glyphicon-copyright-mark:before{content:"\e194"}.glyphicon-registration-mark:before{content:"\e195"}.glyphicon-cloud-download:before{content:"\e197"}.glyphicon-cloud-upload:before{content:"\e198"}.glyphicon-tree-conifer:before{content:"\e199"}.glyphicon-tree-deciduous:before{content:"\e200"}*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}:before,:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}html{font-size:10px;-webkit-tap-highlight-color:rgba(0,0,0,0)}body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.42857143;color:#333;background-color:#fff}input,button,select,textarea{font-family:inherit;font-size:inherit;line-height:inherit}a{color:#337ab7;text-decoration:none}a:hover,a:focus{color:#23527c;text-decoration:underline}a:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}figure{margin:0}img{vertical-align:middle}.img-responsive,.thumbnail>img,.thumbnail a>img,.carousel-inner>.item>img,.carousel-inner>.item>a>img{display:block;max-width:100%;height:auto}.img-rounded{border-radius:6px}.img-thumbnail{display:inline-block;max-width:100%;height:auto;padding:4px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;-o-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.img-circle{border-radius:50%}hr{margin-top:20px;margin-bottom:20px;border:0;border-top:1px solid #eee}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}h1,h2,h3,h4,h5,h6,.h1,.h2,.h3,.h4,.h5,.h6{font-family:inherit;font-weight:500;line-height:1.1;color:inherit}h1 small,h2 small,h3 small,h4 small,h5 small,h6 small,.h1 small,.h2 small,.h3 small,.h4 small,.h5 small,.h6 small,h1 .small,h2 .small,h3 .small,h4 .small,h5 .small,h6 .small,.h1 .small,.h2 .small,.h3 .small,.h4 .small,.h5 .small,.h6 .small{font-weight:400;line-height:1;color:#777}h1,.h1,h2,.h2,h3,.h3{margin-top:20px;margin-bottom:10px}h1 small,.h1 small,h2 small,.h2 small,h3 small,.h3 small,h1 .small,.h1 .small,h2 .small,.h2 .small,h3 .small,.h3 .small{font-size:65%}h4,.h4,h5,.h5,h6,.h6{margin-top:10px;margin-bottom:10px}h4 small,.h4 small,h5 small,.h5 small,h6 small,.h6 small,h4 .small,.h4 .small,h5 .small,.h5 .small,h6 .small,.h6 .small{font-size:75%}h1,.h1{font-size:36px}h2,.h2{font-size:30px}h3,.h3{font-size:24px}h4,.h4{font-size:18px}h5,.h5{font-size:14px}h6,.h6{font-size:12px}p{margin:0 0 10px}.lead{margin-bottom:20px;font-size:16px;font-weight:300;line-height:1.4}@media (min-width:768px){.lead{font-size:21px}}small,.small{font-size:85%}mark,.mark{padding:.2em;background-color:#fcf8e3}.text-left{text-align:left}.text-right{text-align:right}.text-center{text-align:center}.text-justify{text-align:justify}.text-nowrap{white-space:nowrap}.text-lowercase{text-transform:lowercase}.text-uppercase{text-transform:uppercase}.text-capitalize{text-transform:capitalize}.text-muted{color:#777}.text-primary{color:#337ab7}a.text-primary:hover{color:#286090}.text-success{color:#3c763d}a.text-success:hover{color:#2b542c}.text-info{color:#31708f}a.text-info:hover{color:#245269}.text-warning{color:#8a6d3b}a.text-warning:hover{color:#66512c}.text-danger{color:#a94442}a.text-danger:hover{color:#843534}.bg-primary{color:#fff;background-color:#337ab7}a.bg-primary:hover{background-color:#286090}.bg-success{background-color:#dff0d8}a.bg-success:hover{background-color:#c1e2b3}.bg-info{background-color:#d9edf7}a.bg-info:hover{background-color:#afd9ee}.bg-warning{background-color:#fcf8e3}a.bg-warning:hover{background-color:#f7ecb5}.bg-danger{background-color:#f2dede}a.bg-danger:hover{background-color:#e4b9b9}.page-header{padding-bottom:9px;margin:40px 0 20px;border-bottom:1px solid #eee}ul,ol{margin-top:0;margin-bottom:10px}ul ul,ol ul,ul ol,ol ol{margin-bottom:0}.list-unstyled{padding-left:0;list-style:none}.list-inline{padding-left:0;margin-left:-5px;list-style:none}.list-inline>li{display:inline-block;padding-right:5px;padding-left:5px}dl{margin-top:0;margin-bottom:20px}dt,dd{line-height:1.42857143}dt{font-weight:700}dd{margin-left:0}@media (min-width:768px){.dl-horizontal dt{float:left;width:160px;overflow:hidden;clear:left;text-align:right;text-overflow:ellipsis;white-space:nowrap}.dl-horizontal dd{margin-left:180px}}abbr[title],abbr[data-original-title]{cursor:help;border-bottom:1px dotted #777}.initialism{font-size:90%;text-transform:uppercase}blockquote{padding:10px 20px;margin:0 0 20px;font-size:17.5px;border-left:5px solid #eee}blockquote p:last-child,blockquote ul:last-child,blockquote ol:last-child{margin-bottom:0}blockquote footer,blockquote small,blockquote .small{display:block;font-size:80%;line-height:1.42857143;color:#777}blockquote footer:before,blockquote small:before,blockquote .small:before{content:'\2014 \00A0'}.blockquote-reverse,blockquote.pull-right{padding-right:15px;padding-left:0;text-align:right;border-right:5px solid #eee;border-left:0}.blockquote-reverse footer:before,blockquote.pull-right footer:before,.blockquote-reverse small:before,blockquote.pull-right small:before,.blockquote-reverse .small:before,blockquote.pull-right .small:before{content:''}.blockquote-reverse footer:after,blockquote.pull-right footer:after,.blockquote-reverse small:after,blockquote.pull-right small:after,.blockquote-reverse .small:after,blockquote.pull-right .small:after{content:'\00A0 \2014'}address{margin-bottom:20px;font-style:normal;line-height:1.42857143}code,kbd,pre,samp{font-family:Menlo,Monaco,Consolas,"Courier New",monospace}code{padding:2px 4px;font-size:90%;color:#c7254e;background-color:#f9f2f4;border-radius:4px}kbd{padding:2px 4px;font-size:90%;color:#fff;background-color:#333;border-radius:3px;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.25);box-shadow:inset 0 -1px 0 rgba(0,0,0,.25)}kbd kbd{padding:0;font-size:100%;font-weight:700;-webkit-box-shadow:none;box-shadow:none}pre{display:block;padding:9.5px;margin:0 0 10px;font-size:13px;line-height:1.42857143;color:#333;word-break:break-all;word-wrap:break-word;background-color:#f5f5f5;border:1px solid #ccc;border-radius:4px}pre code{padding:0;font-size:inherit;color:inherit;white-space:pre-wrap;background-color:transparent;border-radius:0}.pre-scrollable{max-height:340px;overflow-y:scroll}.container{padding-right:15px;padding-left:15px;margin-right:auto;margin-left:auto}@media (min-width:768px){.container{width:750px}}@media (min-width:992px){.container{width:970px}}@media (min-width:1200px){.container{width:1170px}}.container-fluid{padding-right:15px;padding-left:15px;margin-right:auto;margin-left:auto}.row{margin-right:-15px;margin-left:-15px}.col-xs-1,.col-sm-1,.col-md-1,.col-lg-1,.col-xs-2,.col-sm-2,.col-md-2,.col-lg-2,.col-xs-3,.col-sm-3,.col-md-3,.col-lg-3,.col-xs-4,.col-sm-4,.col-md-4,.col-lg-4,.col-xs-5,.col-sm-5,.col-md-5,.col-lg-5,.col-xs-6,.col-sm-6,.col-md-6,.col-lg-6,.col-xs-7,.col-sm-7,.col-md-7,.col-lg-7,.col-xs-8,.col-sm-8,.col-md-8,.col-lg-8,.col-xs-9,.col-sm-9,.col-md-9,.col-lg-9,.col-xs-10,.col-sm-10,.col-md-10,.col-lg-10,.col-xs-11,.col-sm-11,.col-md-11,.col-lg-11,.col-xs-12,.col-sm-12,.col-md-12,.col-lg-12{position:relative;min-height:1px;padding-right:15px;padding-left:15px}.col-xs-1,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9,.col-xs-10,.col-xs-11,.col-xs-12{float:left}.col-xs-12{width:100%}.col-xs-11{width:91.66666667%}.col-xs-10{width:83.33333333%}.col-xs-9{width:75%}.col-xs-8{width:66.66666667%}.col-xs-7{width:58.33333333%}.col-xs-6{width:50%}.col-xs-5{width:41.66666667%}.col-xs-4{width:33.33333333%}.col-xs-3{width:25%}.col-xs-2{width:16.66666667%}.col-xs-1{width:8.33333333%}.col-xs-pull-12{right:100%}.col-xs-pull-11{right:91.66666667%}.col-xs-pull-10{right:83.33333333%}.col-xs-pull-9{right:75%}.col-xs-pull-8{right:66.66666667%}.col-xs-pull-7{right:58.33333333%}.col-xs-pull-6{right:50%}.col-xs-pull-5{right:41.66666667%}.col-xs-pull-4{right:33.33333333%}.col-xs-pull-3{right:25%}.col-xs-pull-2{right:16.66666667%}.col-xs-pull-1{right:8.33333333%}.col-xs-pull-0{right:auto}.col-xs-push-12{left:100%}.col-xs-push-11{left:91.66666667%}.col-xs-push-10{left:83.33333333%}.col-xs-push-9{left:75%}.col-xs-push-8{left:66.66666667%}.col-xs-push-7{left:58.33333333%}.col-xs-push-6{left:50%}.col-xs-push-5{left:41.66666667%}.col-xs-push-4{left:33.33333333%}.col-xs-push-3{left:25%}.col-xs-push-2{left:16.66666667%}.col-xs-push-1{left:8.33333333%}.col-xs-push-0{left:auto}.col-xs-offset-12{margin-left:100%}.col-xs-offset-11{margin-left:91.66666667%}.col-xs-offset-10{margin-left:83.33333333%}.col-xs-offset-9{margin-left:75%}.col-xs-offset-8{margin-left:66.66666667%}.col-xs-offset-7{margin-left:58.33333333%}.col-xs-offset-6{margin-left:50%}.col-xs-offset-5{margin-left:41.66666667%}.col-xs-offset-4{margin-left:33.33333333%}.col-xs-offset-3{margin-left:25%}.col-xs-offset-2{margin-left:16.66666667%}.col-xs-offset-1{margin-left:8.33333333%}.col-xs-offset-0{margin-left:0}@media (min-width:768px){.col-sm-1,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9,.col-sm-10,.col-sm-11,.col-sm-12{float:left}.col-sm-12{width:100%}.col-sm-11{width:91.66666667%}.col-sm-10{width:83.33333333%}.col-sm-9{width:75%}.col-sm-8{width:66.66666667%}.col-sm-7{width:58.33333333%}.col-sm-6{width:50%}.col-sm-5{width:41.66666667%}.col-sm-4{width:33.33333333%}.col-sm-3{width:25%}.col-sm-2{width:16.66666667%}.col-sm-1{width:8.33333333%}.col-sm-pull-12{right:100%}.col-sm-pull-11{right:91.66666667%}.col-sm-pull-10{right:83.33333333%}.col-sm-pull-9{right:75%}.col-sm-pull-8{right:66.66666667%}.col-sm-pull-7{right:58.33333333%}.col-sm-pull-6{right:50%}.col-sm-pull-5{right:41.66666667%}.col-sm-pull-4{right:33.33333333%}.col-sm-pull-3{right:25%}.col-sm-pull-2{right:16.66666667%}.col-sm-pull-1{right:8.33333333%}.col-sm-pull-0{right:auto}.col-sm-push-12{left:100%}.col-sm-push-11{left:91.66666667%}.col-sm-push-10{left:83.33333333%}.col-sm-push-9{left:75%}.col-sm-push-8{left:66.66666667%}.col-sm-push-7{left:58.33333333%}.col-sm-push-6{left:50%}.col-sm-push-5{left:41.66666667%}.col-sm-push-4{left:33.33333333%}.col-sm-push-3{left:25%}.col-sm-push-2{left:16.66666667%}.col-sm-push-1{left:8.33333333%}.col-sm-push-0{left:auto}.col-sm-offset-12{margin-left:100%}.col-sm-offset-11{margin-left:91.66666667%}.col-sm-offset-10{margin-left:83.33333333%}.col-sm-offset-9{margin-left:75%}.col-sm-offset-8{margin-left:66.66666667%}.col-sm-offset-7{margin-left:58.33333333%}.col-sm-offset-6{margin-left:50%}.col-sm-offset-5{margin-left:41.66666667%}.col-sm-offset-4{margin-left:33.33333333%}.col-sm-offset-3{margin-left:25%}.col-sm-offset-2{margin-left:16.66666667%}.col-sm-offset-1{margin-left:8.33333333%}.col-sm-offset-0{margin-left:0}}@media (min-width:992px){.col-md-1,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9,.col-md-10,.col-md-11,.col-md-12{float:left}.col-md-12{width:100%}.col-md-11{width:91.66666667%}.col-md-10{width:83.33333333%}.col-md-9{width:75%}.col-md-8{width:66.66666667%}.col-md-7{width:58.33333333%}.col-md-6{width:50%}.col-md-5{width:41.66666667%}.col-md-4{width:33.33333333%}.col-md-3{width:25%}.col-md-2{width:16.66666667%}.col-md-1{width:8.33333333%}.col-md-pull-12{right:100%}.col-md-pull-11{right:91.66666667%}.col-md-pull-10{right:83.33333333%}.col-md-pull-9{right:75%}.col-md-pull-8{right:66.66666667%}.col-md-pull-7{right:58.33333333%}.col-md-pull-6{right:50%}.col-md-pull-5{right:41.66666667%}.col-md-pull-4{right:33.33333333%}.col-md-pull-3{right:25%}.col-md-pull-2{right:16.66666667%}.col-md-pull-1{right:8.33333333%}.col-md-pull-0{right:auto}.col-md-push-12{left:100%}.col-md-push-11{left:91.66666667%}.col-md-push-10{left:83.33333333%}.col-md-push-9{left:75%}.col-md-push-8{left:66.66666667%}.col-md-push-7{left:58.33333333%}.col-md-push-6{left:50%}.col-md-push-5{left:41.66666667%}.col-md-push-4{left:33.33333333%}.col-md-push-3{left:25%}.col-md-push-2{left:16.66666667%}.col-md-push-1{left:8.33333333%}.col-md-push-0{left:auto}.col-md-offset-12{margin-left:100%}.col-md-offset-11{margin-left:91.66666667%}.col-md-offset-10{margin-left:83.33333333%}.col-md-offset-9{margin-left:75%}.col-md-offset-8{margin-left:66.66666667%}.col-md-offset-7{margin-left:58.33333333%}.col-md-offset-6{margin-left:50%}.col-md-offset-5{margin-left:41.66666667%}.col-md-offset-4{margin-left:33.33333333%}.col-md-offset-3{margin-left:25%}.col-md-offset-2{margin-left:16.66666667%}.col-md-offset-1{margin-left:8.33333333%}.col-md-offset-0{margin-left:0}}@media (min-width:1200px){.col-lg-1,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9,.col-lg-10,.col-lg-11,.col-lg-12{float:left}.col-lg-12{width:100%}.col-lg-11{width:91.66666667%}.col-lg-10{width:83.33333333%}.col-lg-9{width:75%}.col-lg-8{width:66.66666667%}.col-lg-7{width:58.33333333%}.col-lg-6{width:50%}.col-lg-5{width:41.66666667%}.col-lg-4{width:33.33333333%}.col-lg-3{width:25%}.col-lg-2{width:16.66666667%}.col-lg-1{width:8.33333333%}.col-lg-pull-12{right:100%}.col-lg-pull-11{right:91.66666667%}.col-lg-pull-10{right:83.33333333%}.col-lg-pull-9{right:75%}.col-lg-pull-8{right:66.66666667%}.col-lg-pull-7{right:58.33333333%}.col-lg-pull-6{right:50%}.col-lg-pull-5{right:41.66666667%}.col-lg-pull-4{right:33.33333333%}.col-lg-pull-3{right:25%}.col-lg-pull-2{right:16.66666667%}.col-lg-pull-1{right:8.33333333%}.col-lg-pull-0{right:auto}.col-lg-push-12{left:100%}.col-lg-push-11{left:91.66666667%}.col-lg-push-10{left:83.33333333%}.col-lg-push-9{left:75%}.col-lg-push-8{left:66.66666667%}.col-lg-push-7{left:58.33333333%}.col-lg-push-6{left:50%}.col-lg-push-5{left:41.66666667%}.col-lg-push-4{left:33.33333333%}.col-lg-push-3{left:25%}.col-lg-push-2{left:16.66666667%}.col-lg-push-1{left:8.33333333%}.col-lg-push-0{left:auto}.col-lg-offset-12{margin-left:100%}.col-lg-offset-11{margin-left:91.66666667%}.col-lg-offset-10{margin-left:83.33333333%}.col-lg-offset-9{margin-left:75%}.col-lg-offset-8{margin-left:66.66666667%}.col-lg-offset-7{margin-left:58.33333333%}.col-lg-offset-6{margin-left:50%}.col-lg-offset-5{margin-left:41.66666667%}.col-lg-offset-4{margin-left:33.33333333%}.col-lg-offset-3{margin-left:25%}.col-lg-offset-2{margin-left:16.66666667%}.col-lg-offset-1{margin-left:8.33333333%}.col-lg-offset-0{margin-left:0}}table{background-color:transparent}caption{padding-top:8px;padding-bottom:8px;color:#777;text-align:left}th{text-align:left}.table{width:100%;max-width:100%;margin-bottom:20px}.table>thead>tr>th,.table>tbody>tr>th,.table>tfoot>tr>th,.table>thead>tr>td,.table>tbody>tr>td,.table>tfoot>tr>td{padding:8px;line-height:1.42857143;vertical-align:top;border-top:1px solid #ddd}.table>thead>tr>th{vertical-align:bottom;border-bottom:2px solid #ddd}.table>caption+thead>tr:first-child>th,.table>colgroup+thead>tr:first-child>th,.table>thead:first-child>tr:first-child>th,.table>caption+thead>tr:first-child>td,.table>colgroup+thead>tr:first-child>td,.table>thead:first-child>tr:first-child>td{border-top:0}.table>tbody+tbody{border-top:2px solid #ddd}.table .table{background-color:#fff}.table-condensed>thead>tr>th,.table-condensed>tbody>tr>th,.table-condensed>tfoot>tr>th,.table-condensed>thead>tr>td,.table-condensed>tbody>tr>td,.table-condensed>tfoot>tr>td{padding:5px}.table-bordered{border:1px solid #ddd}.table-bordered>thead>tr>th,.table-bordered>tbody>tr>th,.table-bordered>tfoot>tr>th,.table-bordered>thead>tr>td,.table-bordered>tbody>tr>td,.table-bordered>tfoot>tr>td{border:1px solid #ddd}.table-bordered>thead>tr>th,.table-bordered>thead>tr>td{border-bottom-width:2px}.table-striped>tbody>tr:nth-child(odd){background-color:#f9f9f9}.table-hover>tbody>tr:hover{background-color:#f5f5f5}table col[class*=col-]{position:static;display:table-column;float:none}table td[class*=col-],table th[class*=col-]{position:static;display:table-cell;float:none}.table>thead>tr>td.active,.table>tbody>tr>td.active,.table>tfoot>tr>td.active,.table>thead>tr>th.active,.table>tbody>tr>th.active,.table>tfoot>tr>th.active,.table>thead>tr.active>td,.table>tbody>tr.active>td,.table>tfoot>tr.active>td,.table>thead>tr.active>th,.table>tbody>tr.active>th,.table>tfoot>tr.active>th{background-color:#f5f5f5}.table-hover>tbody>tr>td.active:hover,.table-hover>tbody>tr>th.active:hover,.table-hover>tbody>tr.active:hover>td,.table-hover>tbody>tr:hover>.active,.table-hover>tbody>tr.active:hover>th{background-color:#e8e8e8}.table>thead>tr>td.success,.table>tbody>tr>td.success,.table>tfoot>tr>td.success,.table>thead>tr>th.success,.table>tbody>tr>th.success,.table>tfoot>tr>th.success,.table>thead>tr.success>td,.table>tbody>tr.success>td,.table>tfoot>tr.success>td,.table>thead>tr.success>th,.table>tbody>tr.success>th,.table>tfoot>tr.success>th{background-color:#dff0d8}.table-hover>tbody>tr>td.success:hover,.table-hover>tbody>tr>th.success:hover,.table-hover>tbody>tr.success:hover>td,.table-hover>tbody>tr:hover>.success,.table-hover>tbody>tr.success:hover>th{background-color:#d0e9c6}.table>thead>tr>td.info,.table>tbody>tr>td.info,.table>tfoot>tr>td.info,.table>thead>tr>th.info,.table>tbody>tr>th.info,.table>tfoot>tr>th.info,.table>thead>tr.info>td,.table>tbody>tr.info>td,.table>tfoot>tr.info>td,.table>thead>tr.info>th,.table>tbody>tr.info>th,.table>tfoot>tr.info>th{background-color:#d9edf7}.table-hover>tbody>tr>td.info:hover,.table-hover>tbody>tr>th.info:hover,.table-hover>tbody>tr.info:hover>td,.table-hover>tbody>tr:hover>.info,.table-hover>tbody>tr.info:hover>th{background-color:#c4e3f3}.table>thead>tr>td.warning,.table>tbody>tr>td.warning,.table>tfoot>tr>td.warning,.table>thead>tr>th.warning,.table>tbody>tr>th.warning,.table>tfoot>tr>th.warning,.table>thead>tr.warning>td,.table>tbody>tr.warning>td,.table>tfoot>tr.warning>td,.table>thead>tr.warning>th,.table>tbody>tr.warning>th,.table>tfoot>tr.warning>th{background-color:#fcf8e3}.table-hover>tbody>tr>td.warning:hover,.table-hover>tbody>tr>th.warning:hover,.table-hover>tbody>tr.warning:hover>td,.table-hover>tbody>tr:hover>.warning,.table-hover>tbody>tr.warning:hover>th{background-color:#faf2cc}.table>thead>tr>td.danger,.table>tbody>tr>td.danger,.table>tfoot>tr>td.danger,.table>thead>tr>th.danger,.table>tbody>tr>th.danger,.table>tfoot>tr>th.danger,.table>thead>tr.danger>td,.table>tbody>tr.danger>td,.table>tfoot>tr.danger>td,.table>thead>tr.danger>th,.table>tbody>tr.danger>th,.table>tfoot>tr.danger>th{background-color:#f2dede}.table-hover>tbody>tr>td.danger:hover,.table-hover>tbody>tr>th.danger:hover,.table-hover>tbody>tr.danger:hover>td,.table-hover>tbody>tr:hover>.danger,.table-hover>tbody>tr.danger:hover>th{background-color:#ebcccc}.table-responsive{min-height:.01%;overflow-x:auto}@media screen and (max-width:767px){.table-responsive{width:100%;margin-bottom:15px;overflow-y:hidden;-ms-overflow-style:-ms-autohiding-scrollbar;border:1px solid #ddd}.table-responsive>.table{margin-bottom:0}.table-responsive>.table>thead>tr>th,.table-responsive>.table>tbody>tr>th,.table-responsive>.table>tfoot>tr>th,.table-responsive>.table>thead>tr>td,.table-responsive>.table>tbody>tr>td,.table-responsive>.table>tfoot>tr>td{white-space:nowrap}.table-responsive>.table-bordered{border:0}.table-responsive>.table-bordered>thead>tr>th:first-child,.table-responsive>.table-bordered>tbody>tr>th:first-child,.table-responsive>.table-bordered>tfoot>tr>th:first-child,.table-responsive>.table-bordered>thead>tr>td:first-child,.table-responsive>.table-bordered>tbody>tr>td:first-child,.table-responsive>.table-bordered>tfoot>tr>td:first-child{border-left:0}.table-responsive>.table-bordered>thead>tr>th:last-child,.table-responsive>.table-bordered>tbody>tr>th:last-child,.table-responsive>.table-bordered>tfoot>tr>th:last-child,.table-responsive>.table-bordered>thead>tr>td:last-child,.table-responsive>.table-bordered>tbody>tr>td:last-child,.table-responsive>.table-bordered>tfoot>tr>td:last-child{border-right:0}.table-responsive>.table-bordered>tbody>tr:last-child>th,.table-responsive>.table-bordered>tfoot>tr:last-child>th,.table-responsive>.table-bordered>tbody>tr:last-child>td,.table-responsive>.table-bordered>tfoot>tr:last-child>td{border-bottom:0}}fieldset{min-width:0;padding:0;margin:0;border:0}legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:inherit;color:#333;border:0;border-bottom:1px solid #e5e5e5}label{display:inline-block;max-width:100%;margin-bottom:5px;font-weight:700}input[type=search]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}input[type=radio],input[type=checkbox]{margin:4px 0 0;margin-top:1px \9;line-height:normal}input[type=file]{display:block}input[type=range]{display:block;width:100%}select[multiple],select[size]{height:auto}input[type=file]:focus,input[type=radio]:focus,input[type=checkbox]:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}output{display:block;padding-top:7px;font-size:14px;line-height:1.42857143;color:#555}.form-control{display:block;width:100%;height:34px;padding:6px 12px;font-size:14px;line-height:1.42857143;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,-webkit-box-shadow ease-in-out .15s;-o-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.form-control::-moz-placeholder{color:#999;opacity:1}.form-control:-ms-input-placeholder{color:#999}.form-control::-webkit-input-placeholder{color:#999}.form-control[disabled],.form-control[readonly],fieldset[disabled] .form-control{cursor:not-allowed;background-color:#eee;opacity:1}textarea.form-control{height:auto}input[type=search]{-webkit-appearance:none}@media screen and (-webkit-min-device-pixel-ratio:0){input[type=date],input[type=time],input[type=datetime-local],input[type=month]{line-height:34px}input[type=date].input-sm,input[type=time].input-sm,input[type=datetime-local].input-sm,input[type=month].input-sm{line-height:30px}input[type=date].input-lg,input[type=time].input-lg,input[type=datetime-local].input-lg,input[type=month].input-lg{line-height:46px}}.form-group{margin-bottom:15px}.radio,.checkbox{position:relative;display:block;margin-top:10px;margin-bottom:10px}.radio label,.checkbox label{min-height:20px;padding-left:20px;margin-bottom:0;font-weight:400;cursor:pointer}.radio input[type=radio],.radio-inline input[type=radio],.checkbox input[type=checkbox],.checkbox-inline input[type=checkbox]{position:absolute;margin-top:4px \9;margin-left:-20px}.radio+.radio,.checkbox+.checkbox{margin-top:-5px}.radio-inline,.checkbox-inline{display:inline-block;padding-left:20px;margin-bottom:0;font-weight:400;vertical-align:middle;cursor:pointer}.radio-inline+.radio-inline,.checkbox-inline+.checkbox-inline{margin-top:0;margin-left:10px}input[type=radio][disabled],input[type=checkbox][disabled],input[type=radio].disabled,input[type=checkbox].disabled,fieldset[disabled] input[type=radio],fieldset[disabled] input[type=checkbox]{cursor:not-allowed}.radio-inline.disabled,.checkbox-inline.disabled,fieldset[disabled] .radio-inline,fieldset[disabled] .checkbox-inline{cursor:not-allowed}.radio.disabled label,.checkbox.disabled label,fieldset[disabled] .radio label,fieldset[disabled] .checkbox label{cursor:not-allowed}.form-control-static{padding-top:7px;padding-bottom:7px;margin-bottom:0}.form-control-static.input-lg,.form-control-static.input-sm{padding-right:0;padding-left:0}.input-sm,.form-group-sm .form-control{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-sm,select.form-group-sm .form-control{height:30px;line-height:30px}textarea.input-sm,textarea.form-group-sm .form-control,select[multiple].input-sm,select[multiple].form-group-sm .form-control{height:auto}.input-lg,.form-group-lg .form-control{height:46px;padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}select.input-lg,select.form-group-lg .form-control{height:46px;line-height:46px}textarea.input-lg,textarea.form-group-lg .form-control,select[multiple].input-lg,select[multiple].form-group-lg .form-control{height:auto}.has-feedback{position:relative}.has-feedback .form-control{padding-right:42.5px}.form-control-feedback{position:absolute;top:0;right:0;z-index:2;display:block;width:34px;height:34px;line-height:34px;text-align:center;pointer-events:none}.input-lg+.form-control-feedback{width:46px;height:46px;line-height:46px}.input-sm+.form-control-feedback{width:30px;height:30px;line-height:30px}.has-success .help-block,.has-success .control-label,.has-success .radio,.has-success .checkbox,.has-success .radio-inline,.has-success .checkbox-inline,.has-success.radio label,.has-success.checkbox label,.has-success.radio-inline label,.has-success.checkbox-inline label{color:#3c763d}.has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.has-success .input-group-addon{color:#3c763d;background-color:#dff0d8;border-color:#3c763d}.has-success .form-control-feedback{color:#3c763d}.has-warning .help-block,.has-warning .control-label,.has-warning .radio,.has-warning .checkbox,.has-warning .radio-inline,.has-warning .checkbox-inline,.has-warning.radio label,.has-warning.checkbox label,.has-warning.radio-inline label,.has-warning.checkbox-inline label{color:#8a6d3b}.has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.has-warning .input-group-addon{color:#8a6d3b;background-color:#fcf8e3;border-color:#8a6d3b}.has-warning .form-control-feedback{color:#8a6d3b}.has-error .help-block,.has-error .control-label,.has-error .radio,.has-error .checkbox,.has-error .radio-inline,.has-error .checkbox-inline,.has-error.radio label,.has-error.checkbox label,.has-error.radio-inline label,.has-error.checkbox-inline label{color:#a94442}.has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.has-error .input-group-addon{color:#a94442;background-color:#f2dede;border-color:#a94442}.has-error .form-control-feedback{color:#a94442}.has-feedback label~.form-control-feedback{top:25px}.has-feedback label.sr-only~.form-control-feedback{top:0}.help-block{display:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.form-inline .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.form-inline .form-control-static{display:inline-block}.form-inline .input-group{display:inline-table;vertical-align:middle}.form-inline .input-group .input-group-addon,.form-inline .input-group .input-group-btn,.form-inline .input-group .form-control{width:auto}.form-inline .input-group>.form-control{width:100%}.form-inline .control-label{margin-bottom:0;vertical-align:middle}.form-inline .radio,.form-inline .checkbox{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.form-inline .radio label,.form-inline .checkbox label{padding-left:0}.form-inline .radio input[type=radio],.form-inline .checkbox input[type=checkbox]{position:relative;margin-left:0}.form-inline .has-feedback .form-control-feedback{top:0}}.form-horizontal .radio,.form-horizontal .checkbox,.form-horizontal .radio-inline,.form-horizontal .checkbox-inline{padding-top:7px;margin-top:0;margin-bottom:0}.form-horizontal .radio,.form-horizontal .checkbox{min-height:27px}.form-horizontal .form-group{margin-right:-15px;margin-left:-15px}@media (min-width:768px){.form-horizontal .control-label{padding-top:7px;margin-bottom:0;text-align:right}}.form-horizontal .has-feedback .form-control-feedback{right:15px}@media (min-width:768px){.form-horizontal .form-group-lg .control-label{padding-top:14.3px}}@media (min-width:768px){.form-horizontal .form-group-sm .control-label{padding-top:6px}}.btn{display:inline-block;padding:6px 12px;margin-bottom:0;font-size:14px;font-weight:400;line-height:1.42857143;text-align:center;white-space:nowrap;vertical-align:middle;-ms-touch-action:manipulation;touch-action:manipulation;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-image:none;border:1px solid transparent;border-radius:4px}.btn:focus,.btn:active:focus,.btn.active:focus,.btn.focus,.btn:active.focus,.btn.active.focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}.btn:hover,.btn:focus,.btn.focus{color:#333;text-decoration:none}.btn:active,.btn.active{background-image:none;outline:0;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn.disabled,.btn[disabled],fieldset[disabled] .btn{pointer-events:none;cursor:not-allowed;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none;opacity:.65}.btn-default{color:#333;background-color:#fff;border-color:#ccc}.btn-default:hover,.btn-default:focus,.btn-default.focus,.btn-default:active,.btn-default.active,.open>.dropdown-toggle.btn-default{color:#333;background-color:#e6e6e6;border-color:#adadad}.btn-default:active,.btn-default.active,.open>.dropdown-toggle.btn-default{background-image:none}.btn-default.disabled,.btn-default[disabled],fieldset[disabled] .btn-default,.btn-default.disabled:hover,.btn-default[disabled]:hover,fieldset[disabled] .btn-default:hover,.btn-default.disabled:focus,.btn-default[disabled]:focus,fieldset[disabled] .btn-default:focus,.btn-default.disabled.focus,.btn-default[disabled].focus,fieldset[disabled] .btn-default.focus,.btn-default.disabled:active,.btn-default[disabled]:active,fieldset[disabled] .btn-default:active,.btn-default.disabled.active,.btn-default[disabled].active,fieldset[disabled] .btn-default.active{background-color:#fff;border-color:#ccc}.btn-default .badge{color:#fff;background-color:#333}.btn-primary{color:#fff;background-color:#337ab7;border-color:#2e6da4}.btn-primary:hover,.btn-primary:focus,.btn-primary.focus,.btn-primary:active,.btn-primary.active,.open>.dropdown-toggle.btn-primary{color:#fff;background-color:#286090;border-color:#204d74}.btn-primary:active,.btn-primary.active,.open>.dropdown-toggle.btn-primary{background-image:none}.btn-primary.disabled,.btn-primary[disabled],fieldset[disabled] .btn-primary,.btn-primary.disabled:hover,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary:hover,.btn-primary.disabled:focus,.btn-primary[disabled]:focus,fieldset[disabled] .btn-primary:focus,.btn-primary.disabled.focus,.btn-primary[disabled].focus,fieldset[disabled] .btn-primary.focus,.btn-primary.disabled:active,.btn-primary[disabled]:active,fieldset[disabled] .btn-primary:active,.btn-primary.disabled.active,.btn-primary[disabled].active,fieldset[disabled] .btn-primary.active{background-color:#337ab7;border-color:#2e6da4}.btn-primary .badge{color:#337ab7;background-color:#fff}.btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.btn-success:hover,.btn-success:focus,.btn-success.focus,.btn-success:active,.btn-success.active,.open>.dropdown-toggle.btn-success{color:#fff;background-color:#449d44;border-color:#398439}.btn-success:active,.btn-success.active,.open>.dropdown-toggle.btn-success{background-image:none}.btn-success.disabled,.btn-success[disabled],fieldset[disabled] .btn-success,.btn-success.disabled:hover,.btn-success[disabled]:hover,fieldset[disabled] .btn-success:hover,.btn-success.disabled:focus,.btn-success[disabled]:focus,fieldset[disabled] .btn-success:focus,.btn-success.disabled.focus,.btn-success[disabled].focus,fieldset[disabled] .btn-success.focus,.btn-success.disabled:active,.btn-success[disabled]:active,fieldset[disabled] .btn-success:active,.btn-success.disabled.active,.btn-success[disabled].active,fieldset[disabled] .btn-success.active{background-color:#5cb85c;border-color:#4cae4c}.btn-success .badge{color:#5cb85c;background-color:#fff}.btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.btn-info:hover,.btn-info:focus,.btn-info.focus,.btn-info:active,.btn-info.active,.open>.dropdown-toggle.btn-info{color:#fff;background-color:#31b0d5;border-color:#269abc}.btn-info:active,.btn-info.active,.open>.dropdown-toggle.btn-info{background-image:none}.btn-info.disabled,.btn-info[disabled],fieldset[disabled] .btn-info,.btn-info.disabled:hover,.btn-info[disabled]:hover,fieldset[disabled] .btn-info:hover,.btn-info.disabled:focus,.btn-info[disabled]:focus,fieldset[disabled] .btn-info:focus,.btn-info.disabled.focus,.btn-info[disabled].focus,fieldset[disabled] .btn-info.focus,.btn-info.disabled:active,.btn-info[disabled]:active,fieldset[disabled] .btn-info:active,.btn-info.disabled.active,.btn-info[disabled].active,fieldset[disabled] .btn-info.active{background-color:#5bc0de;border-color:#46b8da}.btn-info .badge{color:#5bc0de;background-color:#fff}.btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.btn-warning:hover,.btn-warning:focus,.btn-warning.focus,.btn-warning:active,.btn-warning.active,.open>.dropdown-toggle.btn-warning{color:#fff;background-color:#ec971f;border-color:#d58512}.btn-warning:active,.btn-warning.active,.open>.dropdown-toggle.btn-warning{background-image:none}.btn-warning.disabled,.btn-warning[disabled],fieldset[disabled] .btn-warning,.btn-warning.disabled:hover,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning:hover,.btn-warning.disabled:focus,.btn-warning[disabled]:focus,fieldset[disabled] .btn-warning:focus,.btn-warning.disabled.focus,.btn-warning[disabled].focus,fieldset[disabled] .btn-warning.focus,.btn-warning.disabled:active,.btn-warning[disabled]:active,fieldset[disabled] .btn-warning:active,.btn-warning.disabled.active,.btn-warning[disabled].active,fieldset[disabled] .btn-warning.active{background-color:#f0ad4e;border-color:#eea236}.btn-warning .badge{color:#f0ad4e;background-color:#fff}.btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.btn-danger:hover,.btn-danger:focus,.btn-danger.focus,.btn-danger:active,.btn-danger.active,.open>.dropdown-toggle.btn-danger{color:#fff;background-color:#c9302c;border-color:#ac2925}.btn-danger:active,.btn-danger.active,.open>.dropdown-toggle.btn-danger{background-image:none}.btn-danger.disabled,.btn-danger[disabled],fieldset[disabled] .btn-danger,.btn-danger.disabled:hover,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger:hover,.btn-danger.disabled:focus,.btn-danger[disabled]:focus,fieldset[disabled] .btn-danger:focus,.btn-danger.disabled.focus,.btn-danger[disabled].focus,fieldset[disabled] .btn-danger.focus,.btn-danger.disabled:active,.btn-danger[disabled]:active,fieldset[disabled] .btn-danger:active,.btn-danger.disabled.active,.btn-danger[disabled].active,fieldset[disabled] .btn-danger.active{background-color:#d9534f;border-color:#d43f3a}.btn-danger .badge{color:#d9534f;background-color:#fff}.btn-link{font-weight:400;color:#337ab7;border-radius:0}.btn-link,.btn-link:active,.btn-link.active,.btn-link[disabled],fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.btn-link,.btn-link:hover,.btn-link:focus,.btn-link:active{border-color:transparent}.btn-link:hover,.btn-link:focus{color:#23527c;text-decoration:underline;background-color:transparent}.btn-link[disabled]:hover,fieldset[disabled] .btn-link:hover,.btn-link[disabled]:focus,fieldset[disabled] .btn-link:focus{color:#777;text-decoration:none}.btn-lg,.btn-group-lg>.btn{padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.btn-sm,.btn-group-sm>.btn{padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.btn-xs,.btn-group-xs>.btn{padding:1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.btn-block{display:block;width:100%}.btn-block+.btn-block{margin-top:5px}input[type=submit].btn-block,input[type=reset].btn-block,input[type=button].btn-block{width:100%}.fade{opacity:0;-webkit-transition:opacity .15s linear;-o-transition:opacity .15s linear;transition:opacity .15s linear}.fade.in{opacity:1}.collapse{display:none;visibility:hidden}.collapse.in{display:block;visibility:visible}tr.collapse.in{display:table-row}tbody.collapse.in{display:table-row-group}.collapsing{position:relative;height:0;overflow:hidden;-webkit-transition-timing-function:ease;-o-transition-timing-function:ease;transition-timing-function:ease;-webkit-transition-duration:.35s;-o-transition-duration:.35s;transition-duration:.35s;-webkit-transition-property:height,visibility;-o-transition-property:height,visibility;transition-property:height,visibility}.caret{display:inline-block;width:0;height:0;margin-left:2px;vertical-align:middle;border-top:4px solid;border-right:4px solid transparent;border-left:4px solid transparent}.dropdown{position:relative}.dropdown-toggle:focus{outline:0}.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;float:left;min-width:160px;padding:5px 0;margin:2px 0 0;font-size:14px;text-align:left;list-style:none;background-color:#fff;-webkit-background-clip:padding-box;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.15);border-radius:4px;-webkit-box-shadow:0 6px 12px rgba(0,0,0,.175);box-shadow:0 6px 12px rgba(0,0,0,.175)}.dropdown-menu.pull-right{right:0;left:auto}.dropdown-menu .divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.dropdown-menu>li>a{display:block;padding:3px 20px;clear:both;font-weight:400;line-height:1.42857143;color:#333;white-space:nowrap}.dropdown-menu>li>a:hover,.dropdown-menu>li>a:focus{color:#262626;text-decoration:none;background-color:#f5f5f5}.dropdown-menu>.active>a,.dropdown-menu>.active>a:hover,.dropdown-menu>.active>a:focus{color:#fff;text-decoration:none;background-color:#337ab7;outline:0}.dropdown-menu>.disabled>a,.dropdown-menu>.disabled>a:hover,.dropdown-menu>.disabled>a:focus{color:#777}.dropdown-menu>.disabled>a:hover,.dropdown-menu>.disabled>a:focus{text-decoration:none;cursor:not-allowed;background-color:transparent;background-image:none;filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.open>.dropdown-menu{display:block}.open>a{outline:0}.dropdown-menu-right{right:0;left:auto}.dropdown-menu-left{right:auto;left:0}.dropdown-header{display:block;padding:3px 20px;font-size:12px;line-height:1.42857143;color:#777;white-space:nowrap}.dropdown-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:990}.pull-right>.dropdown-menu{right:0;left:auto}.dropup .caret,.navbar-fixed-bottom .dropdown .caret{content:"";border-top:0;border-bottom:4px solid}.dropup .dropdown-menu,.navbar-fixed-bottom .dropdown .dropdown-menu{top:auto;bottom:100%;margin-bottom:1px}@media (min-width:768px){.navbar-right .dropdown-menu{right:0;left:auto}.navbar-right .dropdown-menu-left{right:auto;left:0}}.btn-group,.btn-group-vertical{position:relative;display:inline-block;vertical-align:middle}.btn-group>.btn,.btn-group-vertical>.btn{position:relative;float:left}.btn-group>.btn:hover,.btn-group-vertical>.btn:hover,.btn-group>.btn:focus,.btn-group-vertical>.btn:focus,.btn-group>.btn:active,.btn-group-vertical>.btn:active,.btn-group>.btn.active,.btn-group-vertical>.btn.active{z-index:2}.btn-group .btn+.btn,.btn-group .btn+.btn-group,.btn-group .btn-group+.btn,.btn-group .btn-group+.btn-group{margin-left:-1px}.btn-toolbar{margin-left:-5px}.btn-toolbar .btn-group,.btn-toolbar .input-group{float:left}.btn-toolbar>.btn,.btn-toolbar>.btn-group,.btn-toolbar>.input-group{margin-left:5px}.btn-group>.btn:not(:first-child):not(:last-child):not(.dropdown-toggle){border-radius:0}.btn-group>.btn:first-child{margin-left:0}.btn-group>.btn:first-child:not(:last-child):not(.dropdown-toggle){border-top-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn:last-child:not(:first-child),.btn-group>.dropdown-toggle:not(:first-child){border-top-left-radius:0;border-bottom-left-radius:0}.btn-group>.btn-group{float:left}.btn-group>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group>.btn-group:first-child>.btn:last-child,.btn-group>.btn-group:first-child>.dropdown-toggle{border-top-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn-group:last-child>.btn:first-child{border-top-left-radius:0;border-bottom-left-radius:0}.btn-group .dropdown-toggle:active,.btn-group.open .dropdown-toggle{outline:0}.btn-group>.btn+.dropdown-toggle{padding-right:8px;padding-left:8px}.btn-group>.btn-lg+.dropdown-toggle{padding-right:12px;padding-left:12px}.btn-group.open .dropdown-toggle{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn-group.open .dropdown-toggle.btn-link{-webkit-box-shadow:none;box-shadow:none}.btn .caret{margin-left:0}.btn-lg .caret{border-width:5px 5px 0;border-bottom-width:0}.dropup .btn-lg .caret{border-width:0 5px 5px}.btn-group-vertical>.btn,.btn-group-vertical>.btn-group,.btn-group-vertical>.btn-group>.btn{display:block;float:none;width:100%;max-width:100%}.btn-group-vertical>.btn-group>.btn{float:none}.btn-group-vertical>.btn+.btn,.btn-group-vertical>.btn+.btn-group,.btn-group-vertical>.btn-group+.btn,.btn-group-vertical>.btn-group+.btn-group{margin-top:-1px;margin-left:0}.btn-group-vertical>.btn:not(:first-child):not(:last-child){border-radius:0}.btn-group-vertical>.btn:first-child:not(:last-child){border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn:last-child:not(:first-child){border-top-left-radius:0;border-top-right-radius:0;border-bottom-left-radius:4px}.btn-group-vertical>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group-vertical>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group-vertical>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-left-radius:0;border-top-right-radius:0}.btn-group-justified{display:table;width:100%;table-layout:fixed;border-collapse:separate}.btn-group-justified>.btn,.btn-group-justified>.btn-group{display:table-cell;float:none;width:1%}.btn-group-justified>.btn-group .btn{width:100%}.btn-group-justified>.btn-group .dropdown-menu{left:auto}[data-toggle=buttons]>.btn input[type=radio],[data-toggle=buttons]>.btn-group>.btn input[type=radio],[data-toggle=buttons]>.btn input[type=checkbox],[data-toggle=buttons]>.btn-group>.btn input[type=checkbox]{position:absolute;clip:rect(0,0,0,0);pointer-events:none}.input-group{position:relative;display:table;border-collapse:separate}.input-group[class*=col-]{float:none;padding-right:0;padding-left:0}.input-group .form-control{position:relative;z-index:2;float:left;width:100%;margin-bottom:0}.input-group-lg>.form-control,.input-group-lg>.input-group-addon,.input-group-lg>.input-group-btn>.btn{height:46px;padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}select.input-group-lg>.form-control,select.input-group-lg>.input-group-addon,select.input-group-lg>.input-group-btn>.btn{height:46px;line-height:46px}textarea.input-group-lg>.form-control,textarea.input-group-lg>.input-group-addon,textarea.input-group-lg>.input-group-btn>.btn,select[multiple].input-group-lg>.form-control,select[multiple].input-group-lg>.input-group-addon,select[multiple].input-group-lg>.input-group-btn>.btn{height:auto}.input-group-sm>.form-control,.input-group-sm>.input-group-addon,.input-group-sm>.input-group-btn>.btn{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-group-sm>.form-control,select.input-group-sm>.input-group-addon,select.input-group-sm>.input-group-btn>.btn{height:30px;line-height:30px}textarea.input-group-sm>.form-control,textarea.input-group-sm>.input-group-addon,textarea.input-group-sm>.input-group-btn>.btn,select[multiple].input-group-sm>.form-control,select[multiple].input-group-sm>.input-group-addon,select[multiple].input-group-sm>.input-group-btn>.btn{height:auto}.input-group-addon,.input-group-btn,.input-group .form-control{display:table-cell}.input-group-addon:not(:first-child):not(:last-child),.input-group-btn:not(:first-child):not(:last-child),.input-group .form-control:not(:first-child):not(:last-child){border-radius:0}.input-group-addon,.input-group-btn{width:1%;white-space:nowrap;vertical-align:middle}.input-group-addon{padding:6px 12px;font-size:14px;font-weight:400;line-height:1;color:#555;text-align:center;background-color:#eee;border:1px solid #ccc;border-radius:4px}.input-group-addon.input-sm{padding:5px 10px;font-size:12px;border-radius:3px}.input-group-addon.input-lg{padding:10px 16px;font-size:18px;border-radius:6px}.input-group-addon input[type=radio],.input-group-addon input[type=checkbox]{margin-top:0}.input-group .form-control:first-child,.input-group-addon:first-child,.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group>.btn,.input-group-btn:first-child>.dropdown-toggle,.input-group-btn:last-child>.btn:not(:last-child):not(.dropdown-toggle),.input-group-btn:last-child>.btn-group:not(:last-child)>.btn{border-top-right-radius:0;border-bottom-right-radius:0}.input-group-addon:first-child{border-right:0}.input-group .form-control:last-child,.input-group-addon:last-child,.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group>.btn,.input-group-btn:last-child>.dropdown-toggle,.input-group-btn:first-child>.btn:not(:first-child),.input-group-btn:first-child>.btn-group:not(:first-child)>.btn{border-top-left-radius:0;border-bottom-left-radius:0}.input-group-addon:last-child{border-left:0}.input-group-btn{position:relative;font-size:0;white-space:nowrap}.input-group-btn>.btn{position:relative}.input-group-btn>.btn+.btn{margin-left:-1px}.input-group-btn>.btn:hover,.input-group-btn>.btn:focus,.input-group-btn>.btn:active{z-index:2}.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group{margin-right:-1px}.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group{margin-left:-1px}.nav{padding-left:0;margin-bottom:0;list-style:none}.nav>li{position:relative;display:block}.nav>li>a{position:relative;display:block;padding:10px 15px}.nav>li>a:hover,.nav>li>a:focus{text-decoration:none;background-color:#eee}.nav>li.disabled>a{color:#777}.nav>li.disabled>a:hover,.nav>li.disabled>a:focus{color:#777;text-decoration:none;cursor:not-allowed;background-color:transparent}.nav .open>a,.nav .open>a:hover,.nav .open>a:focus{background-color:#eee;border-color:#337ab7}.nav .nav-divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.nav>li>a>img{max-width:none}.nav-tabs{border-bottom:1px solid #ddd}.nav-tabs>li{float:left;margin-bottom:-1px}.nav-tabs>li>a{margin-right:2px;line-height:1.42857143;border:1px solid transparent;border-radius:4px 4px 0 0}.nav-tabs>li>a:hover{border-color:#eee #eee #ddd}.nav-tabs>li.active>a,.nav-tabs>li.active>a:hover,.nav-tabs>li.active>a:focus{color:#555;cursor:default;background-color:#fff;border:1px solid #ddd;border-bottom-color:transparent}.nav-tabs.nav-justified{width:100%;border-bottom:0}.nav-tabs.nav-justified>li{float:none}.nav-tabs.nav-justified>li>a{margin-bottom:5px;text-align:center}.nav-tabs.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-tabs.nav-justified>li{display:table-cell;width:1%}.nav-tabs.nav-justified>li>a{margin-bottom:0}}.nav-tabs.nav-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:hover,.nav-tabs.nav-justified>.active>a:focus{border:1px solid #ddd}@media (min-width:768px){.nav-tabs.nav-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:hover,.nav-tabs.nav-justified>.active>a:focus{border-bottom-color:#fff}}.nav-pills>li{float:left}.nav-pills>li>a{border-radius:4px}.nav-pills>li+li{margin-left:2px}.nav-pills>li.active>a,.nav-pills>li.active>a:hover,.nav-pills>li.active>a:focus{color:#fff;background-color:#337ab7}.nav-stacked>li{float:none}.nav-stacked>li+li{margin-top:2px;margin-left:0}.nav-justified{width:100%}.nav-justified>li{float:none}.nav-justified>li>a{margin-bottom:5px;text-align:center}.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-justified>li{display:table-cell;width:1%}.nav-justified>li>a{margin-bottom:0}}.nav-tabs-justified{border-bottom:0}.nav-tabs-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:hover,.nav-tabs-justified>.active>a:focus{border:1px solid #ddd}@media (min-width:768px){.nav-tabs-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:hover,.nav-tabs-justified>.active>a:focus{border-bottom-color:#fff}}.tab-content>.tab-pane{display:none;visibility:hidden}.tab-content>.active{display:block;visibility:visible}.nav-tabs .dropdown-menu{margin-top:-1px;border-top-left-radius:0;border-top-right-radius:0}.navbar{position:relative;min-height:50px;margin-bottom:20px;border:1px solid transparent}@media (min-width:768px){.navbar{border-radius:4px}}@media (min-width:768px){.navbar-header{float:left}}.navbar-collapse{padding-right:15px;padding-left:15px;overflow-x:visible;-webkit-overflow-scrolling:touch;border-top:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1)}.navbar-collapse.in{overflow-y:auto}@media (min-width:768px){.navbar-collapse{width:auto;border-top:0;-webkit-box-shadow:none;box-shadow:none}.navbar-collapse.collapse{display:block!important;height:auto!important;padding-bottom:0;overflow:visible!important;visibility:visible!important}.navbar-collapse.in{overflow-y:visible}.navbar-fixed-top .navbar-collapse,.navbar-static-top .navbar-collapse,.navbar-fixed-bottom .navbar-collapse{padding-right:0;padding-left:0}}.navbar-fixed-top .navbar-collapse,.navbar-fixed-bottom .navbar-collapse{max-height:340px}@media (max-device-width:480px) and (orientation:landscape){.navbar-fixed-top .navbar-collapse,.navbar-fixed-bottom .navbar-collapse{max-height:200px}}.container>.navbar-header,.container-fluid>.navbar-header,.container>.navbar-collapse,.container-fluid>.navbar-collapse{margin-right:-15px;margin-left:-15px}@media (min-width:768px){.container>.navbar-header,.container-fluid>.navbar-header,.container>.navbar-collapse,.container-fluid>.navbar-collapse{margin-right:0;margin-left:0}}.navbar-static-top{z-index:1000;border-width:0 0 1px}@media (min-width:768px){.navbar-static-top{border-radius:0}}.navbar-fixed-top,.navbar-fixed-bottom{position:fixed;right:0;left:0;z-index:1030}@media (min-width:768px){.navbar-fixed-top,.navbar-fixed-bottom{border-radius:0}}.navbar-fixed-top{top:0;border-width:0 0 1px}.navbar-fixed-bottom{bottom:0;margin-bottom:0;border-width:1px 0 0}.navbar-brand{float:left;height:50px;padding:15px 15px;font-size:18px;line-height:20px}.navbar-brand:hover,.navbar-brand:focus{text-decoration:none}.navbar-brand>img{display:block}@media (min-width:768px){.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand{margin-left:-15px}}.navbar-toggle{position:relative;float:right;padding:9px 10px;margin-top:8px;margin-right:15px;margin-bottom:8px;background-color:transparent;background-image:none;border:1px solid transparent;border-radius:4px}.navbar-toggle:focus{outline:0}.navbar-toggle .icon-bar{display:block;width:22px;height:2px;border-radius:1px}.navbar-toggle .icon-bar+.icon-bar{margin-top:4px}@media (min-width:768px){.navbar-toggle{display:none}}.navbar-nav{margin:7.5px -15px}.navbar-nav>li>a{padding-top:10px;padding-bottom:10px;line-height:20px}@media (max-width:767px){.navbar-nav .open .dropdown-menu{position:static;float:none;width:auto;margin-top:0;background-color:transparent;border:0;-webkit-box-shadow:none;box-shadow:none}.navbar-nav .open .dropdown-menu>li>a,.navbar-nav .open .dropdown-menu .dropdown-header{padding:5px 15px 5px 25px}.navbar-nav .open .dropdown-menu>li>a{line-height:20px}.navbar-nav .open .dropdown-menu>li>a:hover,.navbar-nav .open .dropdown-menu>li>a:focus{background-image:none}}@media (min-width:768px){.navbar-nav{float:left;margin:0}.navbar-nav>li{float:left}.navbar-nav>li>a{padding-top:15px;padding-bottom:15px}}.navbar-form{padding:10px 15px;margin-top:8px;margin-right:-15px;margin-bottom:8px;margin-left:-15px;border-top:1px solid transparent;border-bottom:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1)}@media (min-width:768px){.navbar-form .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.navbar-form .form-control{display:inline-block;width:auto;vertical-align:middle}.navbar-form .form-control-static{display:inline-block}.navbar-form .input-group{display:inline-table;vertical-align:middle}.navbar-form .input-group .input-group-addon,.navbar-form .input-group .input-group-btn,.navbar-form .input-group .form-control{width:auto}.navbar-form .input-group>.form-control{width:100%}.navbar-form .control-label{margin-bottom:0;vertical-align:middle}.navbar-form .radio,.navbar-form .checkbox{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.navbar-form .radio label,.navbar-form .checkbox label{padding-left:0}.navbar-form .radio input[type=radio],.navbar-form .checkbox input[type=checkbox]{position:relative;margin-left:0}.navbar-form .has-feedback .form-control-feedback{top:0}}@media (max-width:767px){.navbar-form .form-group{margin-bottom:5px}.navbar-form .form-group:last-child{margin-bottom:0}}@media (min-width:768px){.navbar-form{width:auto;padding-top:0;padding-bottom:0;margin-right:0;margin-left:0;border:0;-webkit-box-shadow:none;box-shadow:none}}.navbar-nav>li>.dropdown-menu{margin-top:0;border-top-left-radius:0;border-top-right-radius:0}.navbar-fixed-bottom .navbar-nav>li>.dropdown-menu{border-top-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.navbar-btn{margin-top:8px;margin-bottom:8px}.navbar-btn.btn-sm{margin-top:10px;margin-bottom:10px}.navbar-btn.btn-xs{margin-top:14px;margin-bottom:14px}.navbar-text{margin-top:15px;margin-bottom:15px}@media (min-width:768px){.navbar-text{float:left;margin-right:15px;margin-left:15px}}@media (min-width:768px){.navbar-left{float:left!important}.navbar-right{float:right!important;margin-right:-15px}.navbar-right~.navbar-right{margin-right:0}}.navbar-default{background-color:#f8f8f8;border-color:#e7e7e7}.navbar-default .navbar-brand{color:#777}.navbar-default .navbar-brand:hover,.navbar-default .navbar-brand:focus{color:#5e5e5e;background-color:transparent}.navbar-default .navbar-text{color:#777}.navbar-default .navbar-nav>li>a{color:#777}.navbar-default .navbar-nav>li>a:hover,.navbar-default .navbar-nav>li>a:focus{color:#333;background-color:transparent}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.active>a:hover,.navbar-default .navbar-nav>.active>a:focus{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav>.disabled>a,.navbar-default .navbar-nav>.disabled>a:hover,.navbar-default .navbar-nav>.disabled>a:focus{color:#ccc;background-color:transparent}.navbar-default .navbar-toggle{border-color:#ddd}.navbar-default .navbar-toggle:hover,.navbar-default .navbar-toggle:focus{background-color:#ddd}.navbar-default .navbar-toggle .icon-bar{background-color:#888}.navbar-default .navbar-collapse,.navbar-default .navbar-form{border-color:#e7e7e7}.navbar-default .navbar-nav>.open>a,.navbar-default .navbar-nav>.open>a:hover,.navbar-default .navbar-nav>.open>a:focus{color:#555;background-color:#e7e7e7}@media (max-width:767px){.navbar-default .navbar-nav .open .dropdown-menu>li>a{color:#777}.navbar-default .navbar-nav .open .dropdown-menu>li>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>li>a:focus{color:#333;background-color:transparent}.navbar-default .navbar-nav .open .dropdown-menu>.active>a,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:focus{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:hover,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:focus{color:#ccc;background-color:transparent}}.navbar-default .navbar-link{color:#777}.navbar-default .navbar-link:hover{color:#333}.navbar-default .btn-link{color:#777}.navbar-default .btn-link:hover,.navbar-default .btn-link:focus{color:#333}.navbar-default .btn-link[disabled]:hover,fieldset[disabled] .navbar-default .btn-link:hover,.navbar-default .btn-link[disabled]:focus,fieldset[disabled] .navbar-default .btn-link:focus{color:#ccc}.navbar-inverse{background-color:#222;border-color:#080808}.navbar-inverse .navbar-brand{color:#9d9d9d}.navbar-inverse .navbar-brand:hover,.navbar-inverse .navbar-brand:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-text{color:#9d9d9d}.navbar-inverse .navbar-nav>li>a{color:#9d9d9d}.navbar-inverse .navbar-nav>li>a:hover,.navbar-inverse .navbar-nav>li>a:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.active>a:hover,.navbar-inverse .navbar-nav>.active>a:focus{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav>.disabled>a,.navbar-inverse .navbar-nav>.disabled>a:hover,.navbar-inverse .navbar-nav>.disabled>a:focus{color:#444;background-color:transparent}.navbar-inverse .navbar-toggle{border-color:#333}.navbar-inverse .navbar-toggle:hover,.navbar-inverse .navbar-toggle:focus{background-color:#333}.navbar-inverse .navbar-toggle .icon-bar{background-color:#fff}.navbar-inverse .navbar-collapse,.navbar-inverse .navbar-form{border-color:#101010}.navbar-inverse .navbar-nav>.open>a,.navbar-inverse .navbar-nav>.open>a:hover,.navbar-inverse .navbar-nav>.open>a:focus{color:#fff;background-color:#080808}@media (max-width:767px){.navbar-inverse .navbar-nav .open .dropdown-menu>.dropdown-header{border-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu .divider{background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a{color:#9d9d9d}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:focus{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:focus{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:hover,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:focus{color:#444;background-color:transparent}}.navbar-inverse .navbar-link{color:#9d9d9d}.navbar-inverse .navbar-link:hover{color:#fff}.navbar-inverse .btn-link{color:#9d9d9d}.navbar-inverse .btn-link:hover,.navbar-inverse .btn-link:focus{color:#fff}.navbar-inverse .btn-link[disabled]:hover,fieldset[disabled] .navbar-inverse .btn-link:hover,.navbar-inverse .btn-link[disabled]:focus,fieldset[disabled] .navbar-inverse .btn-link:focus{color:#444}.breadcrumb{padding:8px 15px;margin-bottom:20px;list-style:none;background-color:#f5f5f5;border-radius:4px}.breadcrumb>li{display:inline-block}.breadcrumb>li+li:before{padding:0 5px;color:#ccc;content:"/\00a0"}.breadcrumb>.active{color:#777}.pagination{display:inline-block;padding-left:0;margin:20px 0;border-radius:4px}.pagination>li{display:inline}.pagination>li>a,.pagination>li>span{position:relative;float:left;padding:6px 12px;margin-left:-1px;line-height:1.42857143;color:#337ab7;text-decoration:none;background-color:#fff;border:1px solid #ddd}.pagination>li:first-child>a,.pagination>li:first-child>span{margin-left:0;border-top-left-radius:4px;border-bottom-left-radius:4px}.pagination>li:last-child>a,.pagination>li:last-child>span{border-top-right-radius:4px;border-bottom-right-radius:4px}.pagination>li>a:hover,.pagination>li>span:hover,.pagination>li>a:focus,.pagination>li>span:focus{color:#23527c;background-color:#eee;border-color:#ddd}.pagination>.active>a,.pagination>.active>span,.pagination>.active>a:hover,.pagination>.active>span:hover,.pagination>.active>a:focus,.pagination>.active>span:focus{z-index:2;color:#fff;cursor:default;background-color:#337ab7;border-color:#337ab7}.pagination>.disabled>span,.pagination>.disabled>span:hover,.pagination>.disabled>span:focus,.pagination>.disabled>a,.pagination>.disabled>a:hover,.pagination>.disabled>a:focus{color:#777;cursor:not-allowed;background-color:#fff;border-color:#ddd}.pagination-lg>li>a,.pagination-lg>li>span{padding:10px 16px;font-size:18px}.pagination-lg>li:first-child>a,.pagination-lg>li:first-child>span{border-top-left-radius:6px;border-bottom-left-radius:6px}.pagination-lg>li:last-child>a,.pagination-lg>li:last-child>span{border-top-right-radius:6px;border-bottom-right-radius:6px}.pagination-sm>li>a,.pagination-sm>li>span{padding:5px 10px;font-size:12px}.pagination-sm>li:first-child>a,.pagination-sm>li:first-child>span{border-top-left-radius:3px;border-bottom-left-radius:3px}.pagination-sm>li:last-child>a,.pagination-sm>li:last-child>span{border-top-right-radius:3px;border-bottom-right-radius:3px}.pager{padding-left:0;margin:20px 0;text-align:center;list-style:none}.pager li{display:inline}.pager li>a,.pager li>span{display:inline-block;padding:5px 14px;background-color:#fff;border:1px solid #ddd;border-radius:15px}.pager li>a:hover,.pager li>a:focus{text-decoration:none;background-color:#eee}.pager .next>a,.pager .next>span{float:right}.pager .previous>a,.pager .previous>span{float:left}.pager .disabled>a,.pager .disabled>a:hover,.pager .disabled>a:focus,.pager .disabled>span{color:#777;cursor:not-allowed;background-color:#fff}.label{display:inline;padding:.2em .6em .3em;font-size:75%;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.25em}a.label:hover,a.label:focus{color:#fff;text-decoration:none;cursor:pointer}.label:empty{display:none}.btn .label{position:relative;top:-1px}.label-default{background-color:#777}.label-default[href]:hover,.label-default[href]:focus{background-color:#5e5e5e}.label-primary{background-color:#337ab7}.label-primary[href]:hover,.label-primary[href]:focus{background-color:#286090}.label-success{background-color:#5cb85c}.label-success[href]:hover,.label-success[href]:focus{background-color:#449d44}.label-info{background-color:#5bc0de}.label-info[href]:hover,.label-info[href]:focus{background-color:#31b0d5}.label-warning{background-color:#f0ad4e}.label-warning[href]:hover,.label-warning[href]:focus{background-color:#ec971f}.label-danger{background-color:#d9534f}.label-danger[href]:hover,.label-danger[href]:focus{background-color:#c9302c}.badge{display:inline-block;min-width:10px;padding:3px 7px;font-size:12px;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;background-color:#777;border-radius:10px}.badge:empty{display:none}.btn .badge{position:relative;top:-1px}.btn-xs .badge{top:0;padding:1px 5px}a.badge:hover,a.badge:focus{color:#fff;text-decoration:none;cursor:pointer}.list-group-item.active>.badge,.nav-pills>.active>a>.badge{color:#337ab7;background-color:#fff}.list-group-item>.badge{float:right}.list-group-item>.badge+.badge{margin-right:5px}.nav-pills>li>a>.badge{margin-left:3px}.jumbotron{padding:30px 15px;margin-bottom:30px;color:inherit;background-color:#eee}.jumbotron h1,.jumbotron .h1{color:inherit}.jumbotron p{margin-bottom:15px;font-size:21px;font-weight:200}.jumbotron>hr{border-top-color:#d5d5d5}.container .jumbotron,.container-fluid .jumbotron{border-radius:6px}.jumbotron .container{max-width:100%}@media screen and (min-width:768px){.jumbotron{padding:48px 0}.container .jumbotron,.container-fluid .jumbotron{padding-right:60px;padding-left:60px}.jumbotron h1,.jumbotron .h1{font-size:63px}}.thumbnail{display:block;padding:4px;margin-bottom:20px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:border .2s ease-in-out;-o-transition:border .2s ease-in-out;transition:border .2s ease-in-out}.thumbnail>img,.thumbnail a>img{margin-right:auto;margin-left:auto}a.thumbnail:hover,a.thumbnail:focus,a.thumbnail.active{border-color:#337ab7}.thumbnail .caption{padding:9px;color:#333}.alert{padding:15px;margin-bottom:20px;border:1px solid transparent;border-radius:4px}.alert h4{margin-top:0;color:inherit}.alert .alert-link{font-weight:700}.alert>p,.alert>ul{margin-bottom:0}.alert>p+p{margin-top:5px}.alert-dismissable,.alert-dismissible{padding-right:35px}.alert-dismissable .close,.alert-dismissible .close{position:relative;top:-2px;right:-21px;color:inherit}.alert-success{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.alert-success hr{border-top-color:#c9e2b3}.alert-success .alert-link{color:#2b542c}.alert-info{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.alert-info hr{border-top-color:#a6e1ec}.alert-info .alert-link{color:#245269}.alert-warning{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.alert-warning hr{border-top-color:#f7e1b5}.alert-warning .alert-link{color:#66512c}.alert-danger{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.alert-danger hr{border-top-color:#e4b9c0}.alert-danger .alert-link{color:#843534}@-webkit-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@-o-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}.progress{height:20px;margin-bottom:20px;overflow:hidden;background-color:#f5f5f5;border-radius:4px;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}.progress-bar{float:left;width:0;height:100%;font-size:12px;line-height:20px;color:#fff;text-align:center;background-color:#337ab7;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);-webkit-transition:width .6s ease;-o-transition:width .6s ease;transition:width .6s ease}.progress-striped .progress-bar,.progress-bar-striped{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);-webkit-background-size:40px 40px;background-size:40px 40px}.progress.active .progress-bar,.progress-bar.active{-webkit-animation:progress-bar-stripes 2s linear infinite;-o-animation:progress-bar-stripes 2s linear infinite;animation:progress-bar-stripes 2s linear infinite}.progress-bar-success{background-color:#5cb85c}.progress-striped .progress-bar-success{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-info{background-color:#5bc0de}.progress-striped .progress-bar-info{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-warning{background-color:#f0ad4e}.progress-striped .progress-bar-warning{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-danger{background-color:#d9534f}.progress-striped .progress-bar-danger{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.media{margin-top:15px}.media:first-child{margin-top:0}.media-right,.media>.pull-right{padding-left:10px}.media-left,.media>.pull-left{padding-right:10px}.media-left,.media-right,.media-body{display:table-cell;vertical-align:top}.media-middle{vertical-align:middle}.media-bottom{vertical-align:bottom}.media-heading{margin-top:0;margin-bottom:5px}.media-list{padding-left:0;list-style:none}.list-group{padding-left:0;margin-bottom:20px}.list-group-item{position:relative;display:block;padding:10px 15px;margin-bottom:-1px;background-color:#fff;border:1px solid #ddd}.list-group-item:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.list-group-item:last-child{margin-bottom:0;border-bottom-right-radius:4px;border-bottom-left-radius:4px}a.list-group-item{color:#555}a.list-group-item .list-group-item-heading{color:#333}a.list-group-item:hover,a.list-group-item:focus{color:#555;text-decoration:none;background-color:#f5f5f5}.list-group-item.disabled,.list-group-item.disabled:hover,.list-group-item.disabled:focus{color:#777;cursor:not-allowed;background-color:#eee}.list-group-item.disabled .list-group-item-heading,.list-group-item.disabled:hover .list-group-item-heading,.list-group-item.disabled:focus .list-group-item-heading{color:inherit}.list-group-item.disabled .list-group-item-text,.list-group-item.disabled:hover .list-group-item-text,.list-group-item.disabled:focus .list-group-item-text{color:#777}.list-group-item.active,.list-group-item.active:hover,.list-group-item.active:focus{z-index:2;color:#fff;background-color:#337ab7;border-color:#337ab7}.list-group-item.active .list-group-item-heading,.list-group-item.active:hover .list-group-item-heading,.list-group-item.active:focus .list-group-item-heading,.list-group-item.active .list-group-item-heading>small,.list-group-item.active:hover .list-group-item-heading>small,.list-group-item.active:focus .list-group-item-heading>small,.list-group-item.active .list-group-item-heading>.small,.list-group-item.active:hover .list-group-item-heading>.small,.list-group-item.active:focus .list-group-item-heading>.small{color:inherit}.list-group-item.active .list-group-item-text,.list-group-item.active:hover .list-group-item-text,.list-group-item.active:focus .list-group-item-text{color:#c7ddef}.list-group-item-success{color:#3c763d;background-color:#dff0d8}a.list-group-item-success{color:#3c763d}a.list-group-item-success .list-group-item-heading{color:inherit}a.list-group-item-success:hover,a.list-group-item-success:focus{color:#3c763d;background-color:#d0e9c6}a.list-group-item-success.active,a.list-group-item-success.active:hover,a.list-group-item-success.active:focus{color:#fff;background-color:#3c763d;border-color:#3c763d}.list-group-item-info{color:#31708f;background-color:#d9edf7}a.list-group-item-info{color:#31708f}a.list-group-item-info .list-group-item-heading{color:inherit}a.list-group-item-info:hover,a.list-group-item-info:focus{color:#31708f;background-color:#c4e3f3}a.list-group-item-info.active,a.list-group-item-info.active:hover,a.list-group-item-info.active:focus{color:#fff;background-color:#31708f;border-color:#31708f}.list-group-item-warning{color:#8a6d3b;background-color:#fcf8e3}a.list-group-item-warning{color:#8a6d3b}a.list-group-item-warning .list-group-item-heading{color:inherit}a.list-group-item-warning:hover,a.list-group-item-warning:focus{color:#8a6d3b;background-color:#faf2cc}a.list-group-item-warning.active,a.list-group-item-warning.active:hover,a.list-group-item-warning.active:focus{color:#fff;background-color:#8a6d3b;border-color:#8a6d3b}.list-group-item-danger{color:#a94442;background-color:#f2dede}a.list-group-item-danger{color:#a94442}a.list-group-item-danger .list-group-item-heading{color:inherit}a.list-group-item-danger:hover,a.list-group-item-danger:focus{color:#a94442;background-color:#ebcccc}a.list-group-item-danger.active,a.list-group-item-danger.active:hover,a.list-group-item-danger.active:focus{color:#fff;background-color:#a94442;border-color:#a94442}.list-group-item-heading{margin-top:0;margin-bottom:5px}.list-group-item-text{margin-bottom:0;line-height:1.3}.panel{margin-bottom:20px;background-color:#fff;border:1px solid transparent;border-radius:4px;-webkit-box-shadow:0 1px 1px rgba(0,0,0,.05);box-shadow:0 1px 1px rgba(0,0,0,.05)}.panel-body{padding:15px}.panel-heading{padding:10px 15px;border-bottom:1px solid transparent;border-top-left-radius:3px;border-top-right-radius:3px}.panel-heading>.dropdown .dropdown-toggle{color:inherit}.panel-title{margin-top:0;margin-bottom:0;font-size:16px;color:inherit}.panel-title>a{color:inherit}.panel-footer{padding:10px 15px;background-color:#f5f5f5;border-top:1px solid #ddd;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.list-group,.panel>.panel-collapse>.list-group{margin-bottom:0}.panel>.list-group .list-group-item,.panel>.panel-collapse>.list-group .list-group-item{border-width:1px 0;border-radius:0}.panel>.list-group:first-child .list-group-item:first-child,.panel>.panel-collapse>.list-group:first-child .list-group-item:first-child{border-top:0;border-top-left-radius:3px;border-top-right-radius:3px}.panel>.list-group:last-child .list-group-item:last-child,.panel>.panel-collapse>.list-group:last-child .list-group-item:last-child{border-bottom:0;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel-heading+.list-group .list-group-item:first-child{border-top-width:0}.list-group+.panel-footer{border-top-width:0}.panel>.table,.panel>.table-responsive>.table,.panel>.panel-collapse>.table{margin-bottom:0}.panel>.table caption,.panel>.table-responsive>.table caption,.panel>.panel-collapse>.table caption{padding-right:15px;padding-left:15px}.panel>.table:first-child,.panel>.table-responsive:first-child>.table:first-child{border-top-left-radius:3px;border-top-right-radius:3px}.panel>.table:first-child>thead:first-child>tr:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child{border-top-left-radius:3px;border-top-right-radius:3px}.panel>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table:first-child>thead:first-child>tr:first-child th:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:first-child{border-top-left-radius:3px}.panel>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table:first-child>thead:first-child>tr:first-child th:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:last-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:last-child{border-top-right-radius:3px}.panel>.table:last-child,.panel>.table-responsive:last-child>.table:last-child{border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.table:last-child>tbody:last-child>tr:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child{border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:first-child{border-bottom-left-radius:3px}.panel>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:last-child{border-bottom-right-radius:3px}.panel>.panel-body+.table,.panel>.panel-body+.table-responsive,.panel>.table+.panel-body,.panel>.table-responsive+.panel-body{border-top:1px solid #ddd}.panel>.table>tbody:first-child>tr:first-child th,.panel>.table>tbody:first-child>tr:first-child td{border-top:0}.panel>.table-bordered,.panel>.table-responsive>.table-bordered{border:0}.panel>.table-bordered>thead>tr>th:first-child,.panel>.table-responsive>.table-bordered>thead>tr>th:first-child,.panel>.table-bordered>tbody>tr>th:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:first-child,.panel>.table-bordered>tfoot>tr>th:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:first-child,.panel>.table-bordered>thead>tr>td:first-child,.panel>.table-responsive>.table-bordered>thead>tr>td:first-child,.panel>.table-bordered>tbody>tr>td:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:first-child,.panel>.table-bordered>tfoot>tr>td:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:first-child{border-left:0}.panel>.table-bordered>thead>tr>th:last-child,.panel>.table-responsive>.table-bordered>thead>tr>th:last-child,.panel>.table-bordered>tbody>tr>th:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:last-child,.panel>.table-bordered>tfoot>tr>th:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:last-child,.panel>.table-bordered>thead>tr>td:last-child,.panel>.table-responsive>.table-bordered>thead>tr>td:last-child,.panel>.table-bordered>tbody>tr>td:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:last-child,.panel>.table-bordered>tfoot>tr>td:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:last-child{border-right:0}.panel>.table-bordered>thead>tr:first-child>td,.panel>.table-responsive>.table-bordered>thead>tr:first-child>td,.panel>.table-bordered>tbody>tr:first-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>td,.panel>.table-bordered>thead>tr:first-child>th,.panel>.table-responsive>.table-bordered>thead>tr:first-child>th,.panel>.table-bordered>tbody>tr:first-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>th{border-bottom:0}.panel>.table-bordered>tbody>tr:last-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>td,.panel>.table-bordered>tfoot>tr:last-child>td,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>td,.panel>.table-bordered>tbody>tr:last-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>th,.panel>.table-bordered>tfoot>tr:last-child>th,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>th{border-bottom:0}.panel>.table-responsive{margin-bottom:0;border:0}.panel-group{margin-bottom:20px}.panel-group .panel{margin-bottom:0;border-radius:4px}.panel-group .panel+.panel{margin-top:5px}.panel-group .panel-heading{border-bottom:0}.panel-group .panel-heading+.panel-collapse>.panel-body,.panel-group .panel-heading+.panel-collapse>.list-group{border-top:1px solid #ddd}.panel-group .panel-footer{border-top:0}.panel-group .panel-footer+.panel-collapse .panel-body{border-bottom:1px solid #ddd}.panel-default{border-color:#ddd}.panel-default>.panel-heading{color:#333;background-color:#f5f5f5;border-color:#ddd}.panel-default>.panel-heading+.panel-collapse>.panel-body{border-top-color:#ddd}.panel-default>.panel-heading .badge{color:#f5f5f5;background-color:#333}.panel-default>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#ddd}.panel-primary{border-color:#337ab7}.panel-primary>.panel-heading{color:#fff;background-color:#337ab7;border-color:#337ab7}.panel-primary>.panel-heading+.panel-collapse>.panel-body{border-top-color:#337ab7}.panel-primary>.panel-heading .badge{color:#337ab7;background-color:#fff}.panel-primary>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#337ab7}.panel-success{border-color:#d6e9c6}.panel-success>.panel-heading{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.panel-success>.panel-heading+.panel-collapse>.panel-body{border-top-color:#d6e9c6}.panel-success>.panel-heading .badge{color:#dff0d8;background-color:#3c763d}.panel-success>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#d6e9c6}.panel-info{border-color:#bce8f1}.panel-info>.panel-heading{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.panel-info>.panel-heading+.panel-collapse>.panel-body{border-top-color:#bce8f1}.panel-info>.panel-heading .badge{color:#d9edf7;background-color:#31708f}.panel-info>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#bce8f1}.panel-warning{border-color:#faebcc}.panel-warning>.panel-heading{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.panel-warning>.panel-heading+.panel-collapse>.panel-body{border-top-color:#faebcc}.panel-warning>.panel-heading .badge{color:#fcf8e3;background-color:#8a6d3b}.panel-warning>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#faebcc}.panel-danger{border-color:#ebccd1}.panel-danger>.panel-heading{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.panel-danger>.panel-heading+.panel-collapse>.panel-body{border-top-color:#ebccd1}.panel-danger>.panel-heading .badge{color:#f2dede;background-color:#a94442}.panel-danger>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#ebccd1}.embed-responsive{position:relative;display:block;height:0;padding:0;overflow:hidden}.embed-responsive .embed-responsive-item,.embed-responsive iframe,.embed-responsive embed,.embed-responsive object,.embed-responsive video{position:absolute;top:0;bottom:0;left:0;width:100%;height:100%;border:0}.embed-responsive.embed-responsive-16by9{padding-bottom:56.25%}.embed-responsive.embed-responsive-4by3{padding-bottom:75%}.well{min-height:20px;padding:19px;margin-bottom:20px;background-color:#f5f5f5;border:1px solid #e3e3e3;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.05);box-shadow:inset 0 1px 1px rgba(0,0,0,.05)}.well blockquote{border-color:#ddd;border-color:rgba(0,0,0,.15)}.well-lg{padding:24px;border-radius:6px}.well-sm{padding:9px;border-radius:3px}.close{float:right;font-size:21px;font-weight:700;line-height:1;color:#000;text-shadow:0 1px 0 #fff;filter:alpha(opacity=20);opacity:.2}.close:hover,.close:focus{color:#000;text-decoration:none;cursor:pointer;filter:alpha(opacity=50);opacity:.5}button.close{-webkit-appearance:none;padding:0;cursor:pointer;background:0 0;border:0}.modal-open{overflow:hidden}.modal{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1040;display:none;overflow:hidden;-webkit-overflow-scrolling:touch;outline:0}.modal.fade .modal-dialog{-webkit-transition:-webkit-transform .3s ease-out;-o-transition:-o-transform .3s ease-out;transition:transform .3s ease-out;-webkit-transform:translate(0,-25%);-ms-transform:translate(0,-25%);-o-transform:translate(0,-25%);transform:translate(0,-25%)}.modal.in .modal-dialog{-webkit-transform:translate(0,0);-ms-transform:translate(0,0);-o-transform:translate(0,0);transform:translate(0,0)}.modal-open .modal{overflow-x:hidden;overflow-y:auto}.modal-dialog{position:relative;width:auto;margin:10px}.modal-content{position:relative;background-color:#fff;-webkit-background-clip:padding-box;background-clip:padding-box;border:1px solid #999;border:1px solid rgba(0,0,0,.2);border-radius:6px;outline:0;-webkit-box-shadow:0 3px 9px rgba(0,0,0,.5);box-shadow:0 3px 9px rgba(0,0,0,.5)}.modal-backdrop{position:absolute;top:0;right:0;left:0;background-color:#000}.modal-backdrop.fade{filter:alpha(opacity=0);opacity:0}.modal-backdrop.in{filter:alpha(opacity=50);opacity:.5}.modal-header{min-height:16.43px;padding:15px;border-bottom:1px solid #e5e5e5}.modal-header .close{margin-top:-2px}.modal-title{margin:0;line-height:1.42857143}.modal-body{position:relative;padding:15px}.modal-footer{padding:15px;text-align:right;border-top:1px solid #e5e5e5}.modal-footer .btn+.btn{margin-bottom:0;margin-left:5px}.modal-footer .btn-group .btn+.btn{margin-left:-1px}.modal-footer .btn-block+.btn-block{margin-left:0}.modal-scrollbar-measure{position:absolute;top:-9999px;width:50px;height:50px;overflow:scroll}@media (min-width:768px){.modal-dialog{width:600px;margin:30px auto}.modal-content{-webkit-box-shadow:0 5px 15px rgba(0,0,0,.5);box-shadow:0 5px 15px rgba(0,0,0,.5)}.modal-sm{width:300px}}@media (min-width:992px){.modal-lg{width:900px}}.tooltip{position:absolute;z-index:1070;display:block;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:12px;font-weight:400;line-height:1.4;visibility:visible;filter:alpha(opacity=0);opacity:0}.tooltip.in{filter:alpha(opacity=90);opacity:.9}.tooltip.top{padding:5px 0;margin-top:-3px}.tooltip.right{padding:0 5px;margin-left:3px}.tooltip.bottom{padding:5px 0;margin-top:3px}.tooltip.left{padding:0 5px;margin-left:-3px}.tooltip-inner{max-width:200px;padding:3px 8px;color:#fff;text-align:center;text-decoration:none;background-color:#000;border-radius:4px}.tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.tooltip.top .tooltip-arrow{bottom:0;left:50%;margin-left:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-left .tooltip-arrow{right:5px;bottom:0;margin-bottom:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-right .tooltip-arrow{bottom:0;left:5px;margin-bottom:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.right .tooltip-arrow{top:50%;left:0;margin-top:-5px;border-width:5px 5px 5px 0;border-right-color:#000}.tooltip.left .tooltip-arrow{top:50%;right:0;margin-top:-5px;border-width:5px 0 5px 5px;border-left-color:#000}.tooltip.bottom .tooltip-arrow{top:0;left:50%;margin-left:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-left .tooltip-arrow{top:0;right:5px;margin-top:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-right .tooltip-arrow{top:0;left:5px;margin-top:-5px;border-width:0 5px 5px;border-bottom-color:#000}.popover{position:absolute;top:0;left:0;z-index:1060;display:none;max-width:276px;padding:1px;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;font-weight:400;line-height:1.42857143;text-align:left;white-space:normal;background-color:#fff;-webkit-background-clip:padding-box;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);border-radius:6px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,.2);box-shadow:0 5px 10px rgba(0,0,0,.2)}.popover.top{margin-top:-10px}.popover.right{margin-left:10px}.popover.bottom{margin-top:10px}.popover.left{margin-left:-10px}.popover-title{padding:8px 14px;margin:0;font-size:14px;background-color:#f7f7f7;border-bottom:1px solid #ebebeb;border-radius:5px 5px 0 0}.popover-content{padding:9px 14px}.popover>.arrow,.popover>.arrow:after{position:absolute;display:block;width:0;height:0;border-color:transparent;border-style:solid}.popover>.arrow{border-width:11px}.popover>.arrow:after{content:"";border-width:10px}.popover.top>.arrow{bottom:-11px;left:50%;margin-left:-11px;border-top-color:#999;border-top-color:rgba(0,0,0,.25);border-bottom-width:0}.popover.top>.arrow:after{bottom:1px;margin-left:-10px;content:" ";border-top-color:#fff;border-bottom-width:0}.popover.right>.arrow{top:50%;left:-11px;margin-top:-11px;border-right-color:#999;border-right-color:rgba(0,0,0,.25);border-left-width:0}.popover.right>.arrow:after{bottom:-10px;left:1px;content:" ";border-right-color:#fff;border-left-width:0}.popover.bottom>.arrow{top:-11px;left:50%;margin-left:-11px;border-top-width:0;border-bottom-color:#999;border-bottom-color:rgba(0,0,0,.25)}.popover.bottom>.arrow:after{top:1px;margin-left:-10px;content:" ";border-top-width:0;border-bottom-color:#fff}.popover.left>.arrow{top:50%;right:-11px;margin-top:-11px;border-right-width:0;border-left-color:#999;border-left-color:rgba(0,0,0,.25)}.popover.left>.arrow:after{right:1px;bottom:-10px;content:" ";border-right-width:0;border-left-color:#fff}.carousel{position:relative}.carousel-inner{position:relative;width:100%;overflow:hidden}.carousel-inner>.item{position:relative;display:none;-webkit-transition:.6s ease-in-out left;-o-transition:.6s ease-in-out left;transition:.6s ease-in-out left}.carousel-inner>.item>img,.carousel-inner>.item>a>img{line-height:1}@media all and (transform-3d),(-webkit-transform-3d){.carousel-inner>.item{-webkit-transition:-webkit-transform .6s ease-in-out;-o-transition:-o-transform .6s ease-in-out;transition:transform .6s ease-in-out;-webkit-backface-visibility:hidden;backface-visibility:hidden;-webkit-perspective:1000;perspective:1000}.carousel-inner>.item.next,.carousel-inner>.item.active.right{left:0;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}.carousel-inner>.item.prev,.carousel-inner>.item.active.left{left:0;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}.carousel-inner>.item.next.left,.carousel-inner>.item.prev.right,.carousel-inner>.item.active{left:0;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}}.carousel-inner>.active,.carousel-inner>.next,.carousel-inner>.prev{display:block}.carousel-inner>.active{left:0}.carousel-inner>.next,.carousel-inner>.prev{position:absolute;top:0;width:100%}.carousel-inner>.next{left:100%}.carousel-inner>.prev{left:-100%}.carousel-inner>.next.left,.carousel-inner>.prev.right{left:0}.carousel-inner>.active.left{left:-100%}.carousel-inner>.active.right{left:100%}.carousel-control{position:absolute;top:0;bottom:0;left:0;width:15%;font-size:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6);filter:alpha(opacity=50);opacity:.5}.carousel-control.left{background-image:-webkit-linear-gradient(left,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-image:-o-linear-gradient(left,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-image:-webkit-gradient(linear,left top,right top,from(rgba(0,0,0,.5)),to(rgba(0,0,0,.0001)));background-image:linear-gradient(to right,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1);background-repeat:repeat-x}.carousel-control.right{right:0;left:auto;background-image:-webkit-linear-gradient(left,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-image:-o-linear-gradient(left,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-image:-webkit-gradient(linear,left top,right top,from(rgba(0,0,0,.0001)),to(rgba(0,0,0,.5)));background-image:linear-gradient(to right,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);background-repeat:repeat-x}.carousel-control:hover,.carousel-control:focus{color:#fff;text-decoration:none;filter:alpha(opacity=90);outline:0;opacity:.9}.carousel-control .icon-prev,.carousel-control .icon-next,.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right{position:absolute;top:50%;z-index:5;display:inline-block}.carousel-control .icon-prev,.carousel-control .glyphicon-chevron-left{left:50%;margin-left:-10px}.carousel-control .icon-next,.carousel-control .glyphicon-chevron-right{right:50%;margin-right:-10px}.carousel-control .icon-prev,.carousel-control .icon-next{width:20px;height:20px;margin-top:-10px;font-family:serif}.carousel-control .icon-prev:before{content:'\2039'}.carousel-control .icon-next:before{content:'\203a'}.carousel-indicators{position:absolute;bottom:10px;left:50%;z-index:15;width:60%;padding-left:0;margin-left:-30%;text-align:center;list-style:none}.carousel-indicators li{display:inline-block;width:10px;height:10px;margin:1px;text-indent:-999px;cursor:pointer;background-color:#000 \9;background-color:rgba(0,0,0,0);border:1px solid #fff;border-radius:10px}.carousel-indicators .active{width:12px;height:12px;margin:0;background-color:#fff}.carousel-caption{position:absolute;right:15%;bottom:20px;left:15%;z-index:10;padding-top:20px;padding-bottom:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6)}.carousel-caption .btn{text-shadow:none}@media screen and (min-width:768px){.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right,.carousel-control .icon-prev,.carousel-control .icon-next{width:30px;height:30px;margin-top:-15px;font-size:30px}.carousel-control .glyphicon-chevron-left,.carousel-control .icon-prev{margin-left:-15px}.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next{margin-right:-15px}.carousel-caption{right:20%;left:20%;padding-bottom:30px}.carousel-indicators{bottom:20px}}.clearfix:before,.clearfix:after,.dl-horizontal dd:before,.dl-horizontal dd:after,.container:before,.container:after,.container-fluid:before,.container-fluid:after,.row:before,.row:after,.form-horizontal .form-group:before,.form-horizontal .form-group:after,.btn-toolbar:before,.btn-toolbar:after,.btn-group-vertical>.btn-group:before,.btn-group-vertical>.btn-group:after,.nav:before,.nav:after,.navbar:before,.navbar:after,.navbar-header:before,.navbar-header:after,.navbar-collapse:before,.navbar-collapse:after,.pager:before,.pager:after,.panel-body:before,.panel-body:after,.modal-footer:before,.modal-footer:after{display:table;content:" "}.clearfix:after,.dl-horizontal dd:after,.container:after,.container-fluid:after,.row:after,.form-horizontal .form-group:after,.btn-toolbar:after,.btn-group-vertical>.btn-group:after,.nav:after,.navbar:after,.navbar-header:after,.navbar-collapse:after,.pager:after,.panel-body:after,.modal-footer:after{clear:both}.center-block{display:block;margin-right:auto;margin-left:auto}.pull-right{float:right!important}.pull-left{float:left!important}.hide{display:none!important}.show{display:block!important}.invisible{visibility:hidden}.text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.hidden{display:none!important;visibility:hidden!important}.affix{position:fixed}@-ms-viewport{width:device-width}.visible-xs,.visible-sm,.visible-md,.visible-lg{display:none!important}.visible-xs-block,.visible-xs-inline,.visible-xs-inline-block,.visible-sm-block,.visible-sm-inline,.visible-sm-inline-block,.visible-md-block,.visible-md-inline,.visible-md-inline-block,.visible-lg-block,.visible-lg-inline,.visible-lg-inline-block{display:none!important}@media (max-width:767px){.visible-xs{display:block!important}table.visible-xs{display:table}tr.visible-xs{display:table-row!important}th.visible-xs,td.visible-xs{display:table-cell!important}}@media (max-width:767px){.visible-xs-block{display:block!important}}@media (max-width:767px){.visible-xs-inline{display:inline!important}}@media (max-width:767px){.visible-xs-inline-block{display:inline-block!important}}@media (min-width:768px) and (max-width:991px){.visible-sm{display:block!important}table.visible-sm{display:table}tr.visible-sm{display:table-row!important}th.visible-sm,td.visible-sm{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-block{display:block!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-inline{display:inline!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-inline-block{display:inline-block!important}}@media (min-width:992px) and (max-width:1199px){.visible-md{display:block!important}table.visible-md{display:table}tr.visible-md{display:table-row!important}th.visible-md,td.visible-md{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-block{display:block!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-inline{display:inline!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-inline-block{display:inline-block!important}}@media (min-width:1200px){.visible-lg{display:block!important}table.visible-lg{display:table}tr.visible-lg{display:table-row!important}th.visible-lg,td.visible-lg{display:table-cell!important}}@media (min-width:1200px){.visible-lg-block{display:block!important}}@media (min-width:1200px){.visible-lg-inline{display:inline!important}}@media (min-width:1200px){.visible-lg-inline-block{display:inline-block!important}}@media (max-width:767px){.hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.hidden-md{display:none!important}}@media (min-width:1200px){.hidden-lg{display:none!important}}.visible-print{display:none!important}@media print{.visible-print{display:block!important}table.visible-print{display:table}tr.visible-print{display:table-row!important}th.visible-print,td.visible-print{display:table-cell!important}}.visible-print-block{display:none!important}@media print{.visible-print-block{display:block!important}}.visible-print-inline{display:none!important}@media print{.visible-print-inline{display:inline!important}}.visible-print-inline-block{display:none!important}@media print{.visible-print-inline-block{display:inline-block!important}}@media print{.hidden-print{display:none!important}}</style> + <style>/* bootstrap custom style stuff - taken from demo template. */ +/* + * Base structure + */ + +/* Move down content because we have a fixed navbar that is 50px tall */ +body { + padding-top: 50px; +} + + +/* + * Global add-ons + */ + +.sub-header { + padding-bottom: 10px; + border-bottom: 1px solid #eee; +} + +/* + * Top navigation + * Hide default border to remove 1px line. + */ +.navbar-fixed-top { + border: 0; +} + +/* + * Sidebar + */ + +/* Hide for mobile, show later */ +.sidebar { + display: none; +} +@media (min-width: 768px) { + .sidebar { + position: fixed; + top: 51px; + bottom: 0; + left: 0; + z-index: 1000; + display: block; + padding: 20px; + overflow-x: hidden; + overflow-y: auto; /* Scrollable contents if viewport is shorter than content. */ + background-color: #f5f5f5; + border-right: 1px solid #eee; + } +} + +/* Sidebar navigation */ +.nav-sidebar { + margin-right: -21px; /* 20px padding + 1px border */ + margin-bottom: 20px; + margin-left: -20px; +} +.nav-sidebar > li > a { + padding-right: 20px; + padding-left: 20px; +} +.nav-sidebar > .active > a, +.nav-sidebar > .active > a:hover, +.nav-sidebar > .active > a:focus { + color: #fff; + background-color: #428bca; +} + +/* Table in github markdown style (https://gist.github.com/andyferra/2554919#file-github-css-L154) */ +table { + padding: 0; + margin-bottom: 10px; +} +table tr { + border-top: 1px solid #cccccc; + background-color: white; + margin: 0; + padding: 0; +} +table tr:nth-child(2n) { + background-color: #f8f8f8; +} +table tr th { + font-weight: bold; + border: 1px solid #cccccc; + text-align: left; + margin: 0; + padding: 6px 13px; +} +table tr td { + border: 1px solid #cccccc; + text-align: left; + margin: 0; + padding: 6px 13px; +} +table tr th :first-child, table tr td :first-child { + margin-top: 0; +} +table tr th :last-child, table tr td :last-child { + margin-bottom: 1; +} + + +/* + * Main content + */ + +.main { + padding: 20px; +} +@media (min-width: 768px) { + .main { + padding-right: 40px; + padding-left: 40px; + } +} +.main .page-header { + margin-top: 0; +} + +summary { + display: revert; +} + +ul { + list-style-type: none; + padding-left: 10px; +} + +li { + padding: 2px; +} + +pre { + max-height: 500px; + overflow: auto +} + +.rcorners { + border-radius: 10px; + padding: 0px; + border-style: solid; +} + +.light-green { + border: 2px transparent #73AD21; + border-color: #dff0d8; +} + +summary.light-green { + background-color: #dff0d8 +} + +.light-red { + /* */ + border: 2px transparent #f2dede; + border-color: #f2dede; +} + +summary.light-red { + background-color: #f2dede; +} + +.padded { + background-color: #fff; + margin: 10px; +} + +.tooltip .tooltiptext { + visibility: hidden; + width: 120px; + background-color: black; + color: #fff; + text-align: center; + border-radius: 6px; + padding: 5px 0; + + /* Position the tooltip */ + position: absolute; + z-index: 1; +} + +.tooltip:hover .tooltiptext { + visibility: visible; +} + +/* + * Placeholder dashboard ideas + */ + +.placeholders { + margin-bottom: 30px; + text-align: center; +} +.placeholders h4 { + margin-bottom: 0; +} +.placeholder { + margin-bottom: 20px; +} +.placeholder img { + display: inline-block; + border-radius: 50%; +} + +.text-success-custom{ + color: rgba(6, 108, 8, 1); +} +.text-danger-custom{ + font-weight: bold; + color: rgba(213, 24, 20, 1); +} +.panel-danger-custom .panel-title{ + font-weight: bold; + color: rgba(213, 24, 20, 1); +}t status + +.panel-success-custom .panel-title{ + color: rgba(6, 108, 8, 1); +}t status +</style> + + </head> + <body> + + <nav class="navbar navbar-inverse navbar-fixed-top" role="navigation"> + <div class="container-fluid"> + <div class="navbar-header"> + + <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar"> + <span class="sr-only">Toggle navigation</span> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + </button> + <a class="navbar-brand" href="#">Test Results (powered by Planemo)</a> + </div> + <div id="navbar" class="navbar-collapse collapse"> + <ul class="nav navbar-nav navbar-right"> + <li><a href="https://galaxyproject.org">Galaxy</a></li> + <li><a href="https://planemo.readthedocs.org">Planemo</a></li> + </ul> + <div class="navbar-form navbar-right"> + </div> + </div> + </div> + </nav> + + <div class="container-fluid"> + <div id="overview-content" class="row col-md-offset-1 col-md-10"> + </div> + </div> + + <script>/*! jQuery v2.1.1 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */ +!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k={},l=a.document,m="2.1.1",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return n.each(this,a,b)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(n.isPlainObject(d)||(e=n.isArray(d)))?(e?(e=!1,f=c&&n.isArray(c)?c:[]):f=c&&n.isPlainObject(c)?c:{},g[b]=n.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray,isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){return!n.isArray(a)&&a-parseFloat(a)>=0},isPlainObject:function(a){return"object"!==n.type(a)||a.nodeType||n.isWindow(a)?!1:a.constructor&&!j.call(a.constructor.prototype,"isPrototypeOf")?!1:!0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(a){var b,c=eval;a=n.trim(a),a&&(1===a.indexOf("use strict")?(b=l.createElement("script"),b.text=a,l.head.appendChild(b).parentNode.removeChild(b)):c(a))},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=s(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:g.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=s(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(c=a[b],b=a,a=c),n.isFunction(a)?(e=d.call(arguments,2),f=function(){return a.apply(b||this,e.concat(d.call(arguments)))},f.guid=a.guid=a.guid||n.guid++,f):void 0},now:Date.now,support:k}),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+-new Date,v=a.document,w=0,x=0,y=gb(),z=gb(),A=gb(),B=function(a,b){return a===b&&(l=!0),0},C="undefined",D=1<<31,E={}.hasOwnProperty,F=[],G=F.pop,H=F.push,I=F.push,J=F.slice,K=F.indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},L="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",N="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",O=N.replace("w","w#"),P="\\["+M+"*("+N+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+O+"))|)"+M+"*\\]",Q=":("+N+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+P+")*)|.*)\\)|)",R=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),S=new RegExp("^"+M+"*,"+M+"*"),T=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp("="+M+"*([^\\]'\"]*?)"+M+"*\\]","g"),V=new RegExp(Q),W=new RegExp("^"+O+"$"),X={ID:new RegExp("^#("+N+")"),CLASS:new RegExp("^\\.("+N+")"),TAG:new RegExp("^("+N.replace("w","w*")+")"),ATTR:new RegExp("^"+P),PSEUDO:new RegExp("^"+Q),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+L+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/^(?:input|select|textarea|button)$/i,Z=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,_=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ab=/[+~]/,bb=/'|\\/g,cb=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),db=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)};try{I.apply(F=J.call(v.childNodes),v.childNodes),F[v.childNodes.length].nodeType}catch(eb){I={apply:F.length?function(a,b){H.apply(a,J.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fb(a,b,d,e){var f,h,j,k,l,o,r,s,w,x;if((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,d=d||[],!a||"string"!=typeof a)return d;if(1!==(k=b.nodeType)&&9!==k)return[];if(p&&!e){if(f=_.exec(a))if(j=f[1]){if(9===k){if(h=b.getElementById(j),!h||!h.parentNode)return d;if(h.id===j)return d.push(h),d}else if(b.ownerDocument&&(h=b.ownerDocument.getElementById(j))&&t(b,h)&&h.id===j)return d.push(h),d}else{if(f[2])return I.apply(d,b.getElementsByTagName(a)),d;if((j=f[3])&&c.getElementsByClassName&&b.getElementsByClassName)return I.apply(d,b.getElementsByClassName(j)),d}if(c.qsa&&(!q||!q.test(a))){if(s=r=u,w=b,x=9===k&&a,1===k&&"object"!==b.nodeName.toLowerCase()){o=g(a),(r=b.getAttribute("id"))?s=r.replace(bb,"\\$&"):b.setAttribute("id",s),s="[id='"+s+"'] ",l=o.length;while(l--)o[l]=s+qb(o[l]);w=ab.test(a)&&ob(b.parentNode)||b,x=o.join(",")}if(x)try{return I.apply(d,w.querySelectorAll(x)),d}catch(y){}finally{r||b.removeAttribute("id")}}}return i(a.replace(R,"$1"),b,d,e)}function gb(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function hb(a){return a[u]=!0,a}function ib(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function jb(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function kb(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||D)-(~a.sourceIndex||D);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function lb(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function mb(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function nb(a){return hb(function(b){return b=+b,hb(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function ob(a){return a&&typeof a.getElementsByTagName!==C&&a}c=fb.support={},f=fb.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fb.setDocument=function(a){var b,e=a?a.ownerDocument||a:v,g=e.defaultView;return e!==n&&9===e.nodeType&&e.documentElement?(n=e,o=e.documentElement,p=!f(e),g&&g!==g.top&&(g.addEventListener?g.addEventListener("unload",function(){m()},!1):g.attachEvent&&g.attachEvent("onunload",function(){m()})),c.attributes=ib(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ib(function(a){return a.appendChild(e.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=$.test(e.getElementsByClassName)&&ib(function(a){return a.innerHTML="<div class='a'></div><div class='a i'></div>",a.firstChild.className="i",2===a.getElementsByClassName("i").length}),c.getById=ib(function(a){return o.appendChild(a).id=u,!e.getElementsByName||!e.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if(typeof b.getElementById!==C&&p){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){var c=typeof a.getAttributeNode!==C&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return typeof b.getElementsByTagName!==C?b.getElementsByTagName(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return typeof b.getElementsByClassName!==C&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=$.test(e.querySelectorAll))&&(ib(function(a){a.innerHTML="<select msallowclip=''><option selected=''></option></select>",a.querySelectorAll("[msallowclip^='']").length&&q.push("[*^$]="+M+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+M+"*(?:value|"+L+")"),a.querySelectorAll(":checked").length||q.push(":checked")}),ib(function(a){var b=e.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+M+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=$.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ib(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",Q)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=$.test(o.compareDocumentPosition),t=b||$.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===e||a.ownerDocument===v&&t(v,a)?-1:b===e||b.ownerDocument===v&&t(v,b)?1:k?K.call(k,a)-K.call(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,f=a.parentNode,g=b.parentNode,h=[a],i=[b];if(!f||!g)return a===e?-1:b===e?1:f?-1:g?1:k?K.call(k,a)-K.call(k,b):0;if(f===g)return kb(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)i.unshift(c);while(h[d]===i[d])d++;return d?kb(h[d],i[d]):h[d]===v?-1:i[d]===v?1:0},e):n},fb.matches=function(a,b){return fb(a,null,null,b)},fb.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(U,"='$1']"),!(!c.matchesSelector||!p||r&&r.test(b)||q&&q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fb(b,n,null,[a]).length>0},fb.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fb.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&E.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fb.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fb.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fb.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fb.selectors={cacheLength:50,createPseudo:hb,match:X,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(cb,db),a[3]=(a[3]||a[4]||a[5]||"").replace(cb,db),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fb.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fb.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return X.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&V.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(cb,db).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+M+")"+a+"("+M+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||typeof a.getAttribute!==C&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fb.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){k=q[u]||(q[u]={}),j=k[a]||[],n=j[0]===w&&j[1],m=j[0]===w&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[w,n,m];break}}else if(s&&(j=(b[u]||(b[u]={}))[a])&&j[0]===w)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(s&&((l[u]||(l[u]={}))[a]=[w,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fb.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?hb(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=K.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:hb(function(a){var b=[],c=[],d=h(a.replace(R,"$1"));return d[u]?hb(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:hb(function(a){return function(b){return fb(a,b).length>0}}),contains:hb(function(a){return function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:hb(function(a){return W.test(a||"")||fb.error("unsupported lang: "+a),a=a.replace(cb,db).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Z.test(a.nodeName)},input:function(a){return Y.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:nb(function(){return[0]}),last:nb(function(a,b){return[b-1]}),eq:nb(function(a,b,c){return[0>c?c+b:c]}),even:nb(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:nb(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:nb(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:nb(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=lb(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=mb(b);function pb(){}pb.prototype=d.filters=d.pseudos,d.setFilters=new pb,g=fb.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){(!c||(e=S.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=T.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(R," ")}),h=h.slice(c.length));for(g in d.filter)!(e=X[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?fb.error(a):z(a,i).slice(0)};function qb(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function rb(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[u]||(b[u]={}),(h=i[d])&&h[0]===w&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function sb(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function tb(a,b,c){for(var d=0,e=b.length;e>d;d++)fb(a,b[d],c);return c}function ub(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function vb(a,b,c,d,e,f){return d&&!d[u]&&(d=vb(d)),e&&!e[u]&&(e=vb(e,f)),hb(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||tb(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ub(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ub(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?K.call(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ub(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):I.apply(g,r)})}function wb(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=rb(function(a){return a===b},h,!0),l=rb(function(a){return K.call(b,a)>-1},h,!0),m=[function(a,c,d){return!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d))}];f>i;i++)if(c=d.relative[a[i].type])m=[rb(sb(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return vb(i>1&&sb(m),i>1&&qb(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(R,"$1"),c,e>i&&wb(a.slice(i,e)),f>e&&wb(a=a.slice(e)),f>e&&qb(a))}m.push(c)}return sb(m)}function xb(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,m,o,p=0,q="0",r=f&&[],s=[],t=j,u=f||e&&d.find.TAG("*",k),v=w+=null==t?1:Math.random()||.1,x=u.length;for(k&&(j=g!==n&&g);q!==x&&null!=(l=u[q]);q++){if(e&&l){m=0;while(o=a[m++])if(o(l,g,h)){i.push(l);break}k&&(w=v)}c&&((l=!o&&l)&&p--,f&&r.push(l))}if(p+=q,c&&q!==p){m=0;while(o=b[m++])o(r,s,g,h);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=G.call(i));s=ub(s)}I.apply(i,s),k&&!f&&s.length>0&&p+b.length>1&&fb.uniqueSort(i)}return k&&(w=v,j=t),r};return c?hb(f):f}return h=fb.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wb(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xb(e,d)),f.selector=a}return f},i=fb.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(cb,db),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=X.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(cb,db),ab.test(j[0].type)&&ob(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qb(j),!a)return I.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,ab.test(a)&&ob(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ib(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ib(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||jb("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ib(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||jb("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ib(function(a){return null==a.getAttribute("disabled")})||jb(L,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fb}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=n.expr.match.needsContext,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^.[^:#\[\.,]*$/;function x(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(w.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return g.call(b,a)>=0!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=this.length,d=[],e=this;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;c>b;b++)if(n.contains(e[b],this))return!0}));for(b=0;c>b;b++)n.find(a,e[b],d);return d=this.pushStack(c>1?n.unique(d):d),d.selector=this.selector?this.selector+" "+a:a,d},filter:function(a){return this.pushStack(x(this,a||[],!1))},not:function(a){return this.pushStack(x(this,a||[],!0))},is:function(a){return!!x(this,"string"==typeof a&&u.test(a)?n(a):a||[],!1).length}});var y,z=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,A=n.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:z.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||y).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:l,!0)),v.test(c[1])&&n.isPlainObject(b))for(c in b)n.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}return d=l.getElementById(c[2]),d&&d.parentNode&&(this.length=1,this[0]=d),this.context=l,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof y.ready?y.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};A.prototype=n.fn,y=n(l);var B=/^(?:parents|prev(?:Until|All))/,C={children:!0,contents:!0,next:!0,prev:!0};n.extend({dir:function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),n.fn.extend({has:function(a){var b=n(a,this),c=b.length;return this.filter(function(){for(var a=0;c>a;a++)if(n.contains(this,b[a]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=u.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.unique(f):f)},index:function(a){return a?"string"==typeof a?g.call(n(a),this[0]):g.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.unique(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function D(a,b){while((a=a[b])&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return n.dir(a,"parentNode")},parentsUntil:function(a,b,c){return n.dir(a,"parentNode",c)},next:function(a){return D(a,"nextSibling")},prev:function(a){return D(a,"previousSibling")},nextAll:function(a){return n.dir(a,"nextSibling")},prevAll:function(a){return n.dir(a,"previousSibling")},nextUntil:function(a,b,c){return n.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return n.dir(a,"previousSibling",c)},siblings:function(a){return n.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return n.sibling(a.firstChild)},contents:function(a){return a.contentDocument||n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(C[a]||n.unique(e),B.test(a)&&e.reverse()),this.pushStack(e)}});var E=/\S+/g,F={};function G(a){var b=F[a]={};return n.each(a.match(E)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?F[a]||G(a):n.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(b=a.memory&&l,c=!0,g=e||0,e=0,f=h.length,d=!0;h&&f>g;g++)if(h[g].apply(l[0],l[1])===!1&&a.stopOnFalse){b=!1;break}d=!1,h&&(i?i.length&&j(i.shift()):b?h=[]:k.disable())},k={add:function(){if(h){var c=h.length;!function g(b){n.each(b,function(b,c){var d=n.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&g(c)})}(arguments),d?f=h.length:b&&(e=c,j(b))}return this},remove:function(){return h&&n.each(arguments,function(a,b){var c;while((c=n.inArray(b,h,c))>-1)h.splice(c,1),d&&(f>=c&&f--,g>=c&&g--)}),this},has:function(a){return a?n.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],f=0,this},disable:function(){return h=i=b=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,b||k.disable(),this},locked:function(){return!i},fireWith:function(a,b){return!h||c&&!i||(b=b||[],b=[a,b.slice?b.slice():b],d?i.push(b):j(b)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!c}};return k},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&n.isFunction(a.promise)?e:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var H;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(H.resolveWith(l,[n]),n.fn.triggerHandler&&(n(l).triggerHandler("ready"),n(l).off("ready"))))}});function I(){l.removeEventListener("DOMContentLoaded",I,!1),a.removeEventListener("load",I,!1),n.ready()}n.ready.promise=function(b){return H||(H=n.Deferred(),"complete"===l.readyState?setTimeout(n.ready):(l.addEventListener("DOMContentLoaded",I,!1),a.addEventListener("load",I,!1))),H.promise(b)},n.ready.promise();var J=n.access=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)n.access(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f};n.acceptData=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function K(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=n.expando+Math.random()}K.uid=1,K.accepts=n.acceptData,K.prototype={key:function(a){if(!K.accepts(a))return 0;var b={},c=a[this.expando];if(!c){c=K.uid++;try{b[this.expando]={value:c},Object.defineProperties(a,b)}catch(d){b[this.expando]=c,n.extend(a,b)}}return this.cache[c]||(this.cache[c]={}),c},set:function(a,b,c){var d,e=this.key(a),f=this.cache[e];if("string"==typeof b)f[b]=c;else if(n.isEmptyObject(f))n.extend(this.cache[e],b);else for(d in b)f[d]=b[d];return f},get:function(a,b){var c=this.cache[this.key(a)];return void 0===b?c:c[b]},access:function(a,b,c){var d;return void 0===b||b&&"string"==typeof b&&void 0===c?(d=this.get(a,b),void 0!==d?d:this.get(a,n.camelCase(b))):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d,e,f=this.key(a),g=this.cache[f];if(void 0===b)this.cache[f]={};else{n.isArray(b)?d=b.concat(b.map(n.camelCase)):(e=n.camelCase(b),b in g?d=[b,e]:(d=e,d=d in g?[d]:d.match(E)||[])),c=d.length;while(c--)delete g[d[c]]}},hasData:function(a){return!n.isEmptyObject(this.cache[a[this.expando]]||{})},discard:function(a){a[this.expando]&&delete this.cache[a[this.expando]]}};var L=new K,M=new K,N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(O,"-$1").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}M.set(a,b,c)}else c=void 0;return c}n.extend({hasData:function(a){return M.hasData(a)||L.hasData(a)},data:function(a,b,c){return M.access(a,b,c)},removeData:function(a,b){M.remove(a,b) +},_data:function(a,b,c){return L.access(a,b,c)},_removeData:function(a,b){L.remove(a,b)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=M.get(f),1===f.nodeType&&!L.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));L.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){M.set(this,a)}):J(this,function(b){var c,d=n.camelCase(a);if(f&&void 0===b){if(c=M.get(f,a),void 0!==c)return c;if(c=M.get(f,d),void 0!==c)return c;if(c=P(f,d,void 0),void 0!==c)return c}else this.each(function(){var c=M.get(this,d);M.set(this,d,b),-1!==a.indexOf("-")&&void 0!==c&&M.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){M.remove(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=L.get(a,b),c&&(!d||n.isArray(c)?d=L.access(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return L.get(a,c)||L.access(a,c,{empty:n.Callbacks("once memory").add(function(){L.remove(a,[b+"queue",c])})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=L.get(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var Q=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,R=["Top","Right","Bottom","Left"],S=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)},T=/^(?:checkbox|radio)$/i;!function(){var a=l.createDocumentFragment(),b=a.appendChild(l.createElement("div")),c=l.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),k.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="<textarea>x</textarea>",k.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var U="undefined";k.focusinBubbles="onfocusin"in a;var V=/^key/,W=/^(?:mouse|pointer|contextmenu)|click/,X=/^(?:focusinfocus|focusoutblur)$/,Y=/^([^.]*)(?:\.(.+)|)$/;function Z(){return!0}function $(){return!1}function _(){try{return l.activeElement}catch(a){}}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.get(a);if(r){c.handler&&(f=c,c=f.handler,e=f.selector),c.guid||(c.guid=n.guid++),(i=r.events)||(i=r.events={}),(g=r.handle)||(g=r.handle=function(b){return typeof n!==U&&n.event.triggered!==b.type?n.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(E)||[""],j=b.length;while(j--)h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o&&(l=n.event.special[o]||{},o=(e?l.delegateType:l.bindType)||o,l=n.event.special[o]||{},k=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},f),(m=i[o])||(m=i[o]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,p,g)!==!1||a.addEventListener&&a.addEventListener(o,g,!1)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),n.event.global[o]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.hasData(a)&&L.get(a);if(r&&(i=r.events)){b=(b||"").match(E)||[""],j=b.length;while(j--)if(h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=i[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&q!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete i[o])}else for(o in i)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(i)&&(delete r.handle,L.remove(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,m,o,p=[d||l],q=j.call(b,"type")?b.type:b,r=j.call(b,"namespace")?b.namespace.split("."):[];if(g=h=d=d||l,3!==d.nodeType&&8!==d.nodeType&&!X.test(q+n.event.triggered)&&(q.indexOf(".")>=0&&(r=q.split("."),q=r.shift(),r.sort()),k=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=r.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:n.makeArray(c,[b]),o=n.event.special[q]||{},e||!o.trigger||o.trigger.apply(d,c)!==!1)){if(!e&&!o.noBubble&&!n.isWindow(d)){for(i=o.delegateType||q,X.test(i+q)||(g=g.parentNode);g;g=g.parentNode)p.push(g),h=g;h===(d.ownerDocument||l)&&p.push(h.defaultView||h.parentWindow||a)}f=0;while((g=p[f++])&&!b.isPropagationStopped())b.type=f>1?i:o.bindType||q,m=(L.get(g,"events")||{})[b.type]&&L.get(g,"handle"),m&&m.apply(g,c),m=k&&g[k],m&&m.apply&&n.acceptData(g)&&(b.result=m.apply(g,c),b.result===!1&&b.preventDefault());return b.type=q,e||b.isDefaultPrevented()||o._default&&o._default.apply(p.pop(),c)!==!1||!n.acceptData(d)||k&&n.isFunction(d[q])&&!n.isWindow(d)&&(h=d[k],h&&(d[k]=null),n.event.triggered=q,d[q](),n.event.triggered=void 0,h&&(d[k]=h)),b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(L.get(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(g.namespace))&&(a.handleObj=g,a.data=g.data,e=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==e&&(a.result=e)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!==this;i=i.parentNode||this)if(i.disabled!==!0||"click"!==a.type){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>=0:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,d,e,f=b.button;return null==a.pageX&&null!=b.clientX&&(c=a.target.ownerDocument||l,d=c.documentElement,e=c.body,a.pageX=b.clientX+(d&&d.scrollLeft||e&&e.scrollLeft||0)-(d&&d.clientLeft||e&&e.clientLeft||0),a.pageY=b.clientY+(d&&d.scrollTop||e&&e.scrollTop||0)-(d&&d.clientTop||e&&e.clientTop||0)),a.which||void 0===f||(a.which=1&f?1:2&f?3:4&f?2:0),a}},fix:function(a){if(a[n.expando])return a;var b,c,d,e=a.type,f=a,g=this.fixHooks[e];g||(this.fixHooks[e]=g=W.test(e)?this.mouseHooks:V.test(e)?this.keyHooks:{}),d=g.props?this.props.concat(g.props):this.props,a=new n.Event(f),b=d.length;while(b--)c=d[b],a[c]=f[c];return a.target||(a.target=l),3===a.target.nodeType&&(a.target=a.target.parentNode),g.filter?g.filter(a,f):a},special:{load:{noBubble:!0},focus:{trigger:function(){return this!==_()&&this.focus?(this.focus(),!1):void 0},delegateType:"focusin"},blur:{trigger:function(){return this===_()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return"checkbox"===this.type&&this.click&&n.nodeName(this,"input")?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c,d){var e=n.extend(new n.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?n.event.trigger(e,null,b):n.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},n.removeEvent=function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?Z:$):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={isDefaultPrevented:$,isPropagationStopped:$,isImmediatePropagationStopped:$,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=Z,a&&a.preventDefault&&a.preventDefault()},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=Z,a&&a.stopPropagation&&a.stopPropagation()},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=Z,a&&a.stopImmediatePropagation&&a.stopImmediatePropagation(),this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return(!e||e!==d&&!n.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),k.focusinBubbles||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a),!0)};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=L.access(d,b);e||d.addEventListener(a,c,!0),L.access(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=L.access(d,b)-1;e?L.access(d,b,e):(d.removeEventListener(a,c,!0),L.remove(d,b))}}}),n.fn.extend({on:function(a,b,c,d,e){var f,g;if("object"==typeof a){"string"!=typeof b&&(c=c||b,b=void 0);for(g in a)this.on(g,b,c,a[g],e);return this}if(null==c&&null==d?(d=b,c=b=void 0):null==d&&("string"==typeof b?(d=c,c=void 0):(d=c,c=b,b=void 0)),d===!1)d=$;else if(!d)return this;return 1===e&&(f=d,d=function(a){return n().off(a),f.apply(this,arguments)},d.guid=f.guid||(f.guid=n.guid++)),this.each(function(){n.event.add(this,a,d,c,b)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return(b===!1||"function"==typeof b)&&(c=b,b=void 0),c===!1&&(c=$),this.each(function(){n.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}});var ab=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bb=/<([\w:]+)/,cb=/<|&#?\w+;/,db=/<(?:script|style|link)/i,eb=/checked\s*(?:[^=]|=\s*.checked.)/i,fb=/^$|\/(?:java|ecma)script/i,gb=/^true\/(.*)/,hb=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,ib={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ib.optgroup=ib.option,ib.tbody=ib.tfoot=ib.colgroup=ib.caption=ib.thead,ib.th=ib.td;function jb(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function kb(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function lb(a){var b=gb.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function mb(a,b){for(var c=0,d=a.length;d>c;c++)L.set(a[c],"globalEval",!b||L.get(b[c],"globalEval"))}function nb(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(L.hasData(a)&&(f=L.access(a),g=L.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)n.event.add(b,e,j[e][c])}M.hasData(a)&&(h=M.access(a),i=n.extend({},h),M.set(b,i))}}function ob(a,b){var c=a.getElementsByTagName?a.getElementsByTagName(b||"*"):a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&n.nodeName(a,b)?n.merge([a],c):c}function pb(a,b){var c=b.nodeName.toLowerCase();"input"===c&&T.test(a.type)?b.checked=a.checked:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}n.extend({clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=n.contains(a.ownerDocument,a);if(!(k.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(g=ob(h),f=ob(a),d=0,e=f.length;e>d;d++)pb(f[d],g[d]);if(b)if(c)for(f=f||ob(a),g=g||ob(h),d=0,e=f.length;e>d;d++)nb(f[d],g[d]);else nb(a,h);return g=ob(h,"script"),g.length>0&&mb(g,!i&&ob(a,"script")),h},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,k=b.createDocumentFragment(),l=[],m=0,o=a.length;o>m;m++)if(e=a[m],e||0===e)if("object"===n.type(e))n.merge(l,e.nodeType?[e]:e);else if(cb.test(e)){f=f||k.appendChild(b.createElement("div")),g=(bb.exec(e)||["",""])[1].toLowerCase(),h=ib[g]||ib._default,f.innerHTML=h[1]+e.replace(ab,"<$1></$2>")+h[2],j=h[0];while(j--)f=f.lastChild;n.merge(l,f.childNodes),f=k.firstChild,f.textContent=""}else l.push(b.createTextNode(e));k.textContent="",m=0;while(e=l[m++])if((!d||-1===n.inArray(e,d))&&(i=n.contains(e.ownerDocument,e),f=ob(k.appendChild(e),"script"),i&&mb(f),c)){j=0;while(e=f[j++])fb.test(e.type||"")&&c.push(e)}return k},cleanData:function(a){for(var b,c,d,e,f=n.event.special,g=0;void 0!==(c=a[g]);g++){if(n.acceptData(c)&&(e=c[L.expando],e&&(b=L.cache[e]))){if(b.events)for(d in b.events)f[d]?n.event.remove(c,d):n.removeEvent(c,d,b.handle);L.cache[e]&&delete L.cache[e]}delete M.cache[c[M.expando]]}}}),n.fn.extend({text:function(a){return J(this,function(a){return void 0===a?n.text(this):this.empty().each(function(){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&(this.textContent=a)})},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?n.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||n.cleanData(ob(c)),c.parentNode&&(b&&n.contains(c.ownerDocument,c)&&mb(ob(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(n.cleanData(ob(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return J(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!db.test(a)&&!ib[(bb.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(ab,"<$1></$2>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(ob(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,n.cleanData(ob(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,l=this.length,m=this,o=l-1,p=a[0],q=n.isFunction(p);if(q||l>1&&"string"==typeof p&&!k.checkClone&&eb.test(p))return this.each(function(c){var d=m.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(l&&(c=n.buildFragment(a,this[0].ownerDocument,!1,this),d=c.firstChild,1===c.childNodes.length&&(c=d),d)){for(f=n.map(ob(c,"script"),kb),g=f.length;l>j;j++)h=c,j!==o&&(h=n.clone(h,!0,!0),g&&n.merge(f,ob(h,"script"))),b.call(this[j],h,j);if(g)for(i=f[f.length-1].ownerDocument,n.map(f,lb),j=0;g>j;j++)h=f[j],fb.test(h.type||"")&&!L.access(h,"globalEval")&&n.contains(i,h)&&(h.src?n._evalUrl&&n._evalUrl(h.src):n.globalEval(h.textContent.replace(hb,"")))}return this}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=[],e=n(a),g=e.length-1,h=0;g>=h;h++)c=h===g?this:this.clone(!0),n(e[h])[b](c),f.apply(d,c.get());return this.pushStack(d)}});var qb,rb={};function sb(b,c){var d,e=n(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:n.css(e[0],"display");return e.detach(),f}function tb(a){var b=l,c=rb[a];return c||(c=sb(a,b),"none"!==c&&c||(qb=(qb||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=qb[0].contentDocument,b.write(),b.close(),c=sb(a,b),qb.detach()),rb[a]=c),c}var ub=/^margin/,vb=new RegExp("^("+Q+")(?!px)[a-z%]+$","i"),wb=function(a){return a.ownerDocument.defaultView.getComputedStyle(a,null)};function xb(a,b,c){var d,e,f,g,h=a.style;return c=c||wb(a),c&&(g=c.getPropertyValue(b)||c[b]),c&&(""!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),vb.test(g)&&ub.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0!==g?g+"":g}function yb(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}!function(){var b,c,d=l.documentElement,e=l.createElement("div"),f=l.createElement("div");if(f.style){f.style.backgroundClip="content-box",f.cloneNode(!0).style.backgroundClip="",k.clearCloneStyle="content-box"===f.style.backgroundClip,e.style.cssText="border:0;width:0;height:0;top:0;left:-9999px;margin-top:1px;position:absolute",e.appendChild(f);function g(){f.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",f.innerHTML="",d.appendChild(e);var g=a.getComputedStyle(f,null);b="1%"!==g.top,c="4px"===g.width,d.removeChild(e)}a.getComputedStyle&&n.extend(k,{pixelPosition:function(){return g(),b},boxSizingReliable:function(){return null==c&&g(),c},reliableMarginRight:function(){var b,c=f.appendChild(l.createElement("div"));return c.style.cssText=f.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",c.style.marginRight=c.style.width="0",f.style.width="1px",d.appendChild(e),b=!parseFloat(a.getComputedStyle(c,null).marginRight),d.removeChild(e),b}})}}(),n.swap=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};var zb=/^(none|table(?!-c[ea]).+)/,Ab=new RegExp("^("+Q+")(.*)$","i"),Bb=new RegExp("^([+-])=("+Q+")","i"),Cb={position:"absolute",visibility:"hidden",display:"block"},Db={letterSpacing:"0",fontWeight:"400"},Eb=["Webkit","O","Moz","ms"];function Fb(a,b){if(b in a)return b;var c=b[0].toUpperCase()+b.slice(1),d=b,e=Eb.length;while(e--)if(b=Eb[e]+c,b in a)return b;return d}function Gb(a,b,c){var d=Ab.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function Hb(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+R[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+R[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+R[f]+"Width",!0,e))):(g+=n.css(a,"padding"+R[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+R[f]+"Width",!0,e)));return g}function Ib(a,b,c){var d=!0,e="width"===b?a.offsetWidth:a.offsetHeight,f=wb(a),g="border-box"===n.css(a,"boxSizing",!1,f);if(0>=e||null==e){if(e=xb(a,b,f),(0>e||null==e)&&(e=a.style[b]),vb.test(e))return e;d=g&&(k.boxSizingReliable()||e===a.style[b]),e=parseFloat(e)||0}return e+Hb(a,b,c||(g?"border":"content"),d,f)+"px"}function Jb(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=L.get(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&S(d)&&(f[g]=L.access(d,"olddisplay",tb(d.nodeName)))):(e=S(d),"none"===c&&e||L.set(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=xb(a,"opacity");return""===c?"1":c}}}},cssNumber:{columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;return b=n.cssProps[h]||(n.cssProps[h]=Fb(i,h)),g=n.cssHooks[b]||n.cssHooks[h],void 0===c?g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b]:(f=typeof c,"string"===f&&(e=Bb.exec(c))&&(c=(e[1]+1)*e[2]+parseFloat(n.css(a,b)),f="number"),null!=c&&c===c&&("number"!==f||n.cssNumber[h]||(c+="px"),k.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),g&&"set"in g&&void 0===(c=g.set(a,c,d))||(i[b]=c)),void 0)}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=Fb(a.style,h)),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(e=g.get(a,!0,c)),void 0===e&&(e=xb(a,b,d)),"normal"===e&&b in Db&&(e=Db[b]),""===c||c?(f=parseFloat(e),c===!0||n.isNumeric(f)?f||0:e):e}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?zb.test(n.css(a,"display"))&&0===a.offsetWidth?n.swap(a,Cb,function(){return Ib(a,b,d)}):Ib(a,b,d):void 0},set:function(a,c,d){var e=d&&wb(a);return Gb(a,c,d?Hb(a,b,d,"border-box"===n.css(a,"boxSizing",!1,e),e):0)}}}),n.cssHooks.marginRight=yb(k.reliableMarginRight,function(a,b){return b?n.swap(a,{display:"inline-block"},xb,[a,"marginRight"]):void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+R[d]+b]=f[d]||f[d-2]||f[0];return e}},ub.test(a)||(n.cssHooks[a+b].set=Gb)}),n.fn.extend({css:function(a,b){return J(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=wb(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)},a,b,arguments.length>1)},show:function(){return Jb(this,!0)},hide:function(){return Jb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){S(this)?n(this).show():n(this).hide()})}});function Kb(a,b,c,d,e){return new Kb.prototype.init(a,b,c,d,e)}n.Tween=Kb,Kb.prototype={constructor:Kb,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=Kb.propHooks[this.prop];return a&&a.get?a.get(this):Kb.propHooks._default.get(this)},run:function(a){var b,c=Kb.propHooks[this.prop];return this.pos=b=this.options.duration?n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):Kb.propHooks._default.set(this),this}},Kb.prototype.init.prototype=Kb.prototype,Kb.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[n.cssProps[a.prop]]||n.cssHooks[a.prop])?n.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},Kb.propHooks.scrollTop=Kb.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},n.fx=Kb.prototype.init,n.fx.step={};var Lb,Mb,Nb=/^(?:toggle|show|hide)$/,Ob=new RegExp("^(?:([+-])=|)("+Q+")([a-z%]*)$","i"),Pb=/queueHooks$/,Qb=[Vb],Rb={"*":[function(a,b){var c=this.createTween(a,b),d=c.cur(),e=Ob.exec(b),f=e&&e[3]||(n.cssNumber[a]?"":"px"),g=(n.cssNumber[a]||"px"!==f&&+d)&&Ob.exec(n.css(c.elem,a)),h=1,i=20;if(g&&g[3]!==f){f=f||g[3],e=e||[],g=+d||1;do h=h||".5",g/=h,n.style(c.elem,a,g+f);while(h!==(h=c.cur()/d)&&1!==h&&--i)}return e&&(g=c.start=+g||+d||0,c.unit=f,c.end=e[1]?g+(e[1]+1)*e[2]:+e[2]),c}]};function Sb(){return setTimeout(function(){Lb=void 0}),Lb=n.now()}function Tb(a,b){var c,d=0,e={height:a};for(b=b?1:0;4>d;d+=2-b)c=R[d],e["margin"+c]=e["padding"+c]=a;return b&&(e.opacity=e.width=a),e}function Ub(a,b,c){for(var d,e=(Rb[b]||[]).concat(Rb["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function Vb(a,b,c){var d,e,f,g,h,i,j,k,l=this,m={},o=a.style,p=a.nodeType&&S(a),q=L.get(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,l.always(function(){l.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[o.overflow,o.overflowX,o.overflowY],j=n.css(a,"display"),k="none"===j?L.get(a,"olddisplay")||tb(a.nodeName):j,"inline"===k&&"none"===n.css(a,"float")&&(o.display="inline-block")),c.overflow&&(o.overflow="hidden",l.always(function(){o.overflow=c.overflow[0],o.overflowX=c.overflow[1],o.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],Nb.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(p?"hide":"show")){if("show"!==e||!q||void 0===q[d])continue;p=!0}m[d]=q&&q[d]||n.style(a,d)}else j=void 0;if(n.isEmptyObject(m))"inline"===("none"===j?tb(a.nodeName):j)&&(o.display=j);else{q?"hidden"in q&&(p=q.hidden):q=L.access(a,"fxshow",{}),f&&(q.hidden=!p),p?n(a).show():l.done(function(){n(a).hide()}),l.done(function(){var b;L.remove(a,"fxshow");for(b in m)n.style(a,b,m[b])});for(d in m)g=Ub(p?q[d]:0,d,l),d in q||(q[d]=g.start,p&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function Wb(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function Xb(a,b,c){var d,e,f=0,g=Qb.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=Lb||Sb(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:Lb||Sb(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;for(Wb(k,j.opts.specialEasing);g>f;f++)if(d=Qb[f].call(j,a,k,j.opts))return d;return n.map(k,Ub,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(Xb,{tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;e>d;d++)c=a[d],Rb[c]=Rb[c]||[],Rb[c].unshift(b)},prefilter:function(a,b){b?Qb.unshift(a):Qb.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(S).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=Xb(this,n.extend({},a),f);(e||L.get(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=L.get(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&Pb.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));(b||!c)&&n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=L.get(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(Tb(b,!0),a,d,e)}}),n.each({slideDown:Tb("show"),slideUp:Tb("hide"),slideToggle:Tb("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=0,c=n.timers;for(Lb=n.now();b<c.length;b++)a=c[b],a()||c[b]!==a||c.splice(b--,1);c.length||n.fx.stop(),Lb=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){Mb||(Mb=setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){clearInterval(Mb),Mb=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(a,b){return a=n.fx?n.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},function(){var a=l.createElement("input"),b=l.createElement("select"),c=b.appendChild(l.createElement("option"));a.type="checkbox",k.checkOn=""!==a.value,k.optSelected=c.selected,b.disabled=!0,k.optDisabled=!c.disabled,a=l.createElement("input"),a.value="t",a.type="radio",k.radioValue="t"===a.value}();var Yb,Zb,$b=n.expr.attrHandle;n.fn.extend({attr:function(a,b){return J(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(a&&3!==f&&8!==f&&2!==f)return typeof a.getAttribute===U?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),d=n.attrHooks[b]||(n.expr.match.bool.test(b)?Zb:Yb)),void 0===c?d&&"get"in d&&null!==(e=d.get(a,b))?e:(e=n.find.attr(a,b),null==e?void 0:e):null!==c?d&&"set"in d&&void 0!==(e=d.set(a,c,b))?e:(a.setAttribute(b,c+""),c):void n.removeAttr(a,b)) +},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(E);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)&&(a[d]=!1),a.removeAttribute(c)},attrHooks:{type:{set:function(a,b){if(!k.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}}}),Zb={set:function(a,b,c){return b===!1?n.removeAttr(a,c):a.setAttribute(c,c),c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=$b[b]||n.find.attr;$b[b]=function(a,b,d){var e,f;return d||(f=$b[b],$b[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,$b[b]=f),e}});var _b=/^(?:input|select|textarea|button)$/i;n.fn.extend({prop:function(a,b){return J(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return this.each(function(){delete this[n.propFix[a]||a]})}}),n.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(a,b,c){var d,e,f,g=a.nodeType;if(a&&3!==g&&8!==g&&2!==g)return f=1!==g||!n.isXMLDoc(a),f&&(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){return a.hasAttribute("tabindex")||_b.test(a.nodeName)||a.href?a.tabIndex:-1}}}}),k.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&b.parentNode&&b.parentNode.selectedIndex,null}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this});var ac=/[\t\r\n\f]/g;n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h="string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ac," "):" ")){f=0;while(e=b[f++])d.indexOf(" "+e+" ")<0&&(d+=e+" ");g=n.trim(d),c.className!==g&&(c.className=g)}return this},removeClass:function(a){var b,c,d,e,f,g,h=0===arguments.length||"string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ac," "):"")){f=0;while(e=b[f++])while(d.indexOf(" "+e+" ")>=0)d=d.replace(" "+e+" "," ");g=a?n.trim(d):"",c.className!==g&&(c.className=g)}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):this.each(n.isFunction(a)?function(c){n(this).toggleClass(a.call(this,c,this.className,b),b)}:function(){if("string"===c){var b,d=0,e=n(this),f=a.match(E)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else(c===U||"boolean"===c)&&(this.className&&L.set(this,"__className__",this.className),this.className=this.className||a===!1?"":L.get(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;d>c;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(ac," ").indexOf(b)>=0)return!0;return!1}});var bc=/\r/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(bc,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a))}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],!(!c.selected&&i!==e||(k.optDisabled?c.disabled:null!==c.getAttribute("disabled"))||c.parentNode.disabled&&n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)d=e[g],(d.selected=n.inArray(d.value,f)>=0)&&(c=!0);return c||(a.selectedIndex=-1),f}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>=0:void 0}},k.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}});var cc=n.now(),dc=/\?/;n.parseJSON=function(a){return JSON.parse(a+"")},n.parseXML=function(a){var b,c;if(!a||"string"!=typeof a)return null;try{c=new DOMParser,b=c.parseFromString(a,"text/xml")}catch(d){b=void 0}return(!b||b.getElementsByTagName("parsererror").length)&&n.error("Invalid XML: "+a),b};var ec,fc,gc=/#.*$/,hc=/([?&])_=[^&]*/,ic=/^(.*?):[ \t]*([^\r\n]*)$/gm,jc=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,kc=/^(?:GET|HEAD)$/,lc=/^\/\//,mc=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,nc={},oc={},pc="*/".concat("*");try{fc=location.href}catch(qc){fc=l.createElement("a"),fc.href="",fc=fc.href}ec=mc.exec(fc.toLowerCase())||[];function rc(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(E)||[];if(n.isFunction(c))while(d=f[e++])"+"===d[0]?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function sc(a,b,c,d){var e={},f=a===oc;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function tc(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(c in b)void 0!==b[c]&&((e[c]?a:d||(d={}))[c]=b[c]);return d&&n.extend(!0,a,d),a}function uc(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===d&&(d=a.mimeType||b.getResponseHeader("Content-Type"));if(d)for(e in h)if(h[e]&&h[e].test(d)){i.unshift(e);break}if(i[0]in c)f=i[0];else{for(e in c){if(!i[0]||a.converters[e+" "+i[0]]){f=e;break}g||(g=e)}f=f||g}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function vc(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:fc,type:"GET",isLocal:jc.test(ec[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":pc,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?tc(tc(a,n.ajaxSettings),b):tc(n.ajaxSettings,a)},ajaxPrefilter:rc(nc),ajaxTransport:rc(oc),ajax:function(a,b){"object"==typeof a&&(b=a,a=void 0),b=b||{};var c,d,e,f,g,h,i,j,k=n.ajaxSetup({},b),l=k.context||k,m=k.context&&(l.nodeType||l.jquery)?n(l):n.event,o=n.Deferred(),p=n.Callbacks("once memory"),q=k.statusCode||{},r={},s={},t=0,u="canceled",v={readyState:0,getResponseHeader:function(a){var b;if(2===t){if(!f){f={};while(b=ic.exec(e))f[b[1].toLowerCase()]=b[2]}b=f[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===t?e:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return t||(a=s[c]=s[c]||a,r[a]=b),this},overrideMimeType:function(a){return t||(k.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>t)for(b in a)q[b]=[q[b],a[b]];else v.always(a[v.status]);return this},abort:function(a){var b=a||u;return c&&c.abort(b),x(0,b),this}};if(o.promise(v).complete=p.add,v.success=v.done,v.error=v.fail,k.url=((a||k.url||fc)+"").replace(gc,"").replace(lc,ec[1]+"//"),k.type=b.method||b.type||k.method||k.type,k.dataTypes=n.trim(k.dataType||"*").toLowerCase().match(E)||[""],null==k.crossDomain&&(h=mc.exec(k.url.toLowerCase()),k.crossDomain=!(!h||h[1]===ec[1]&&h[2]===ec[2]&&(h[3]||("http:"===h[1]?"80":"443"))===(ec[3]||("http:"===ec[1]?"80":"443")))),k.data&&k.processData&&"string"!=typeof k.data&&(k.data=n.param(k.data,k.traditional)),sc(nc,k,b,v),2===t)return v;i=k.global,i&&0===n.active++&&n.event.trigger("ajaxStart"),k.type=k.type.toUpperCase(),k.hasContent=!kc.test(k.type),d=k.url,k.hasContent||(k.data&&(d=k.url+=(dc.test(d)?"&":"?")+k.data,delete k.data),k.cache===!1&&(k.url=hc.test(d)?d.replace(hc,"$1_="+cc++):d+(dc.test(d)?"&":"?")+"_="+cc++)),k.ifModified&&(n.lastModified[d]&&v.setRequestHeader("If-Modified-Since",n.lastModified[d]),n.etag[d]&&v.setRequestHeader("If-None-Match",n.etag[d])),(k.data&&k.hasContent&&k.contentType!==!1||b.contentType)&&v.setRequestHeader("Content-Type",k.contentType),v.setRequestHeader("Accept",k.dataTypes[0]&&k.accepts[k.dataTypes[0]]?k.accepts[k.dataTypes[0]]+("*"!==k.dataTypes[0]?", "+pc+"; q=0.01":""):k.accepts["*"]);for(j in k.headers)v.setRequestHeader(j,k.headers[j]);if(k.beforeSend&&(k.beforeSend.call(l,v,k)===!1||2===t))return v.abort();u="abort";for(j in{success:1,error:1,complete:1})v[j](k[j]);if(c=sc(oc,k,b,v)){v.readyState=1,i&&m.trigger("ajaxSend",[v,k]),k.async&&k.timeout>0&&(g=setTimeout(function(){v.abort("timeout")},k.timeout));try{t=1,c.send(r,x)}catch(w){if(!(2>t))throw w;x(-1,w)}}else x(-1,"No Transport");function x(a,b,f,h){var j,r,s,u,w,x=b;2!==t&&(t=2,g&&clearTimeout(g),c=void 0,e=h||"",v.readyState=a>0?4:0,j=a>=200&&300>a||304===a,f&&(u=uc(k,v,f)),u=vc(k,u,v,j),j?(k.ifModified&&(w=v.getResponseHeader("Last-Modified"),w&&(n.lastModified[d]=w),w=v.getResponseHeader("etag"),w&&(n.etag[d]=w)),204===a||"HEAD"===k.type?x="nocontent":304===a?x="notmodified":(x=u.state,r=u.data,s=u.error,j=!s)):(s=x,(a||!x)&&(x="error",0>a&&(a=0))),v.status=a,v.statusText=(b||x)+"",j?o.resolveWith(l,[r,x,v]):o.rejectWith(l,[v,x,s]),v.statusCode(q),q=void 0,i&&m.trigger(j?"ajaxSuccess":"ajaxError",[v,k,j?r:s]),p.fireWith(l,[v,x]),i&&(m.trigger("ajaxComplete",[v,k]),--n.active||n.event.trigger("ajaxStop")))}return v},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax({url:a,type:b,dataType:e,data:c,success:d})}}),n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){var b;return n.isFunction(a)?this.each(function(b){n(this).wrapAll(a.call(this,b))}):(this[0]&&(b=n(a,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstElementChild)a=a.firstElementChild;return a}).append(this)),this)},wrapInner:function(a){return this.each(n.isFunction(a)?function(b){n(this).wrapInner(a.call(this,b))}:function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}}),n.expr.filters.hidden=function(a){return a.offsetWidth<=0&&a.offsetHeight<=0},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var wc=/%20/g,xc=/\[\]$/,yc=/\r?\n/g,zc=/^(?:submit|button|image|reset|file)$/i,Ac=/^(?:input|select|textarea|keygen)/i;function Bc(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||xc.test(a)?d(a,e):Bc(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)Bc(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)Bc(c,a[c],b,e);return d.join("&").replace(wc,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&Ac.test(this.nodeName)&&!zc.test(a)&&(this.checked||!T.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(yc,"\r\n")}}):{name:b.name,value:c.replace(yc,"\r\n")}}).get()}}),n.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(a){}};var Cc=0,Dc={},Ec={0:200,1223:204},Fc=n.ajaxSettings.xhr();a.ActiveXObject&&n(a).on("unload",function(){for(var a in Dc)Dc[a]()}),k.cors=!!Fc&&"withCredentials"in Fc,k.ajax=Fc=!!Fc,n.ajaxTransport(function(a){var b;return k.cors||Fc&&!a.crossDomain?{send:function(c,d){var e,f=a.xhr(),g=++Cc;if(f.open(a.type,a.url,a.async,a.username,a.password),a.xhrFields)for(e in a.xhrFields)f[e]=a.xhrFields[e];a.mimeType&&f.overrideMimeType&&f.overrideMimeType(a.mimeType),a.crossDomain||c["X-Requested-With"]||(c["X-Requested-With"]="XMLHttpRequest");for(e in c)f.setRequestHeader(e,c[e]);b=function(a){return function(){b&&(delete Dc[g],b=f.onload=f.onerror=null,"abort"===a?f.abort():"error"===a?d(f.status,f.statusText):d(Ec[f.status]||f.status,f.statusText,"string"==typeof f.responseText?{text:f.responseText}:void 0,f.getAllResponseHeaders()))}},f.onload=b(),f.onerror=b("error"),b=Dc[g]=b("abort");try{f.send(a.hasContent&&a.data||null)}catch(h){if(b)throw h}},abort:function(){b&&b()}}:void 0}),n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET")}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c;return{send:function(d,e){b=n("<script>").prop({async:!0,charset:a.scriptCharset,src:a.url}).on("load error",c=function(a){b.remove(),c=null,a&&e("error"===a.type?404:200,a.type)}),l.head.appendChild(b[0])},abort:function(){c&&c()}}}});var Gc=[],Hc=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Gc.pop()||n.expando+"_"+cc++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(Hc.test(b.url)?"url":"string"==typeof b.data&&!(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&Hc.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(Hc,"$1"+e):b.jsonp!==!1&&(b.url+=(dc.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,Gc.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||l;var d=v.exec(a),e=!c&&[];return d?[b.createElement(d[1])]:(d=n.buildFragment([a],b,e),e&&e.length&&n(e).remove(),n.merge([],d.childNodes))};var Ic=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&Ic)return Ic.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>=0&&(d=n.trim(a.slice(h)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e,dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).complete(c&&function(a,b){g.each(c,f||[a.responseText,b,a])}),this},n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};var Jc=a.document.documentElement;function Kc(a){return n.isWindow(a)?a:9===a.nodeType&&a.defaultView}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&(f+i).indexOf("auto")>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,h)),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d=this[0],e={top:0,left:0},f=d&&d.ownerDocument;if(f)return b=f.documentElement,n.contains(b,d)?(typeof d.getBoundingClientRect!==U&&(e=d.getBoundingClientRect()),c=Kc(f),{top:e.top+c.pageYOffset-b.clientTop,left:e.left+c.pageXOffset-b.clientLeft}):e},position:function(){if(this[0]){var a,b,c=this[0],d={top:0,left:0};return"fixed"===n.css(c,"position")?b=c.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(d=a.offset()),d.top+=n.css(a[0],"borderTopWidth",!0),d.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-d.top-n.css(c,"marginTop",!0),left:b.left-d.left-n.css(c,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||Jc;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Jc})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(b,c){var d="pageYOffset"===c;n.fn[b]=function(e){return J(this,function(b,e,f){var g=Kc(b);return void 0===f?g?g[c]:b[e]:void(g?g.scrollTo(d?a.pageXOffset:f,d?f:a.pageYOffset):b[e]=f)},b,e,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=yb(k.pixelPosition,function(a,c){return c?(c=xb(a,b),vb.test(c)?n(a).position()[b]+"px":c):void 0})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return J(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var Lc=a.jQuery,Mc=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=Mc),b&&a.jQuery===n&&(a.jQuery=Lc),n},typeof b===U&&(a.jQuery=a.$=n),n}); +//# sourceMappingURL=jquery.min.map</script> + <script>/*! + * Bootstrap v3.3.1 (http://getbootstrap.com) + * Copyright 2011-2014 Twitter, Inc. + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) + */ +if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){var b=a.fn.jquery.split(" ")[0].split(".");if(b[0]<2&&b[1]<9||1==b[0]&&9==b[1]&&b[2]<1)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher")}(jQuery),+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one("bsTransitionEnd",function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b(),a.support.transition&&(a.event.special.bsTransitionEnd={bindType:a.support.transition.end,delegateType:a.support.transition.end,handle:function(b){return a(b.target).is(this)?b.handleObj.handler.apply(this,arguments):void 0}})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var c=a(this),e=c.data("bs.alert");e||c.data("bs.alert",e=new d(this)),"string"==typeof b&&e[b].call(c)})}var c='[data-dismiss="alert"]',d=function(b){a(b).on("click",c,this.close)};d.VERSION="3.3.1",d.TRANSITION_DURATION=150,d.prototype.close=function(b){function c(){g.detach().trigger("closed.bs.alert").remove()}var e=a(this),f=e.attr("data-target");f||(f=e.attr("href"),f=f&&f.replace(/.*(?=#[^\s]*$)/,""));var g=a(f);b&&b.preventDefault(),g.length||(g=e.closest(".alert")),g.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(g.removeClass("in"),a.support.transition&&g.hasClass("fade")?g.one("bsTransitionEnd",c).emulateTransitionEnd(d.TRANSITION_DURATION):c())};var e=a.fn.alert;a.fn.alert=b,a.fn.alert.Constructor=d,a.fn.alert.noConflict=function(){return a.fn.alert=e,this},a(document).on("click.bs.alert.data-api",c,d.prototype.close)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof b&&b;e||d.data("bs.button",e=new c(this,f)),"toggle"==b?e.toggle():b&&e.setState(b)})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.isLoading=!1};c.VERSION="3.3.1",c.DEFAULTS={loadingText:"loading..."},c.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",null==f.resetText&&d.data("resetText",d[e]()),setTimeout(a.proxy(function(){d[e](null==f[b]?this.options[b]:f[b]),"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c))},this),0)},c.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")&&(c.prop("checked")&&this.$element.hasClass("active")?a=!1:b.find(".active").removeClass("active")),a&&c.prop("checked",!this.$element.hasClass("active")).trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active"));a&&this.$element.toggleClass("active")};var d=a.fn.button;a.fn.button=b,a.fn.button.Constructor=c,a.fn.button.noConflict=function(){return a.fn.button=d,this},a(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(c){var d=a(c.target);d.hasClass("btn")||(d=d.closest(".btn")),b.call(d,"toggle"),c.preventDefault()}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(b){a(b.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(b.type))})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b),g="string"==typeof b?b:f.slide;e||d.data("bs.carousel",e=new c(this,f)),"number"==typeof b?e.to(b):g?e[g]():f.interval&&e.pause().cycle()})}var c=function(b,c){this.$element=a(b),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=this.sliding=this.interval=this.$active=this.$items=null,this.options.keyboard&&this.$element.on("keydown.bs.carousel",a.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",a.proxy(this.pause,this)).on("mouseleave.bs.carousel",a.proxy(this.cycle,this))};c.VERSION="3.3.1",c.TRANSITION_DURATION=600,c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},c.prototype.keydown=function(a){if(!/input|textarea/i.test(a.target.tagName)){switch(a.which){case 37:this.prev();break;case 39:this.next();break;default:return}a.preventDefault()}},c.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(a){return this.$items=a.parent().children(".item"),this.$items.index(a||this.$active)},c.prototype.getItemForDirection=function(a,b){var c="prev"==a?-1:1,d=this.getItemIndex(b),e=(d+c)%this.$items.length;return this.$items.eq(e)},c.prototype.to=function(a){var b=this,c=this.getItemIndex(this.$active=this.$element.find(".item.active"));return a>this.$items.length-1||0>a?void 0:this.sliding?this.$element.one("slid.bs.carousel",function(){b.to(a)}):c==a?this.pause().cycle():this.slide(a>c?"next":"prev",this.$items.eq(a))},c.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){return this.sliding?void 0:this.slide("next")},c.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},c.prototype.slide=function(b,d){var e=this.$element.find(".item.active"),f=d||this.getItemForDirection(b,e),g=this.interval,h="next"==b?"left":"right",i="next"==b?"first":"last",j=this;if(!f.length){if(!this.options.wrap)return;f=this.$element.find(".item")[i]()}if(f.hasClass("active"))return this.sliding=!1;var k=f[0],l=a.Event("slide.bs.carousel",{relatedTarget:k,direction:h});if(this.$element.trigger(l),!l.isDefaultPrevented()){if(this.sliding=!0,g&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var m=a(this.$indicators.children()[this.getItemIndex(f)]);m&&m.addClass("active")}var n=a.Event("slid.bs.carousel",{relatedTarget:k,direction:h});return a.support.transition&&this.$element.hasClass("slide")?(f.addClass(b),f[0].offsetWidth,e.addClass(h),f.addClass(h),e.one("bsTransitionEnd",function(){f.removeClass([b,h].join(" ")).addClass("active"),e.removeClass(["active",h].join(" ")),j.sliding=!1,setTimeout(function(){j.$element.trigger(n)},0)}).emulateTransitionEnd(c.TRANSITION_DURATION)):(e.removeClass("active"),f.addClass("active"),this.sliding=!1,this.$element.trigger(n)),g&&this.cycle(),this}};var d=a.fn.carousel;a.fn.carousel=b,a.fn.carousel.Constructor=c,a.fn.carousel.noConflict=function(){return a.fn.carousel=d,this};var e=function(c){var d,e=a(this),f=a(e.attr("data-target")||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""));if(f.hasClass("carousel")){var g=a.extend({},f.data(),e.data()),h=e.attr("data-slide-to");h&&(g.interval=!1),b.call(f,g),h&&f.data("bs.carousel").to(h),c.preventDefault()}};a(document).on("click.bs.carousel.data-api","[data-slide]",e).on("click.bs.carousel.data-api","[data-slide-to]",e),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var c=a(this);b.call(c,c.data())})})}(jQuery),+function(a){"use strict";function b(b){var c,d=b.attr("data-target")||(c=b.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,"");return a(d)}function c(b){return this.each(function(){var c=a(this),e=c.data("bs.collapse"),f=a.extend({},d.DEFAULTS,c.data(),"object"==typeof b&&b);!e&&f.toggle&&"show"==b&&(f.toggle=!1),e||c.data("bs.collapse",e=new d(this,f)),"string"==typeof b&&e[b]()})}var d=function(b,c){this.$element=a(b),this.options=a.extend({},d.DEFAULTS,c),this.$trigger=a(this.options.trigger).filter('[href="#'+b.id+'"], [data-target="#'+b.id+'"]'),this.transitioning=null,this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger),this.options.toggle&&this.toggle()};d.VERSION="3.3.1",d.TRANSITION_DURATION=350,d.DEFAULTS={toggle:!0,trigger:'[data-toggle="collapse"]'},d.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},d.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var b,e=this.$parent&&this.$parent.find("> .panel").children(".in, .collapsing");if(!(e&&e.length&&(b=e.data("bs.collapse"),b&&b.transitioning))){var f=a.Event("show.bs.collapse");if(this.$element.trigger(f),!f.isDefaultPrevented()){e&&e.length&&(c.call(e,"hide"),b||e.data("bs.collapse",null));var g=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[g](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1;var h=function(){this.$element.removeClass("collapsing").addClass("collapse in")[g](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return h.call(this);var i=a.camelCase(["scroll",g].join("-"));this.$element.one("bsTransitionEnd",a.proxy(h,this)).emulateTransitionEnd(d.TRANSITION_DURATION)[g](this.$element[0][i])}}}},d.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1;var e=function(){this.transitioning=0,this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")};return a.support.transition?void this.$element[c](0).one("bsTransitionEnd",a.proxy(e,this)).emulateTransitionEnd(d.TRANSITION_DURATION):e.call(this)}}},d.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()},d.prototype.getParent=function(){return a(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(a.proxy(function(c,d){var e=a(d);this.addAriaAndCollapsedClass(b(e),e)},this)).end()},d.prototype.addAriaAndCollapsedClass=function(a,b){var c=a.hasClass("in");a.attr("aria-expanded",c),b.toggleClass("collapsed",!c).attr("aria-expanded",c)};var e=a.fn.collapse;a.fn.collapse=c,a.fn.collapse.Constructor=d,a.fn.collapse.noConflict=function(){return a.fn.collapse=e,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(d){var e=a(this);e.attr("data-target")||d.preventDefault();var f=b(e),g=f.data("bs.collapse"),h=g?"toggle":a.extend({},e.data(),{trigger:this});c.call(f,h)})}(jQuery),+function(a){"use strict";function b(b){b&&3===b.which||(a(e).remove(),a(f).each(function(){var d=a(this),e=c(d),f={relatedTarget:this};e.hasClass("open")&&(e.trigger(b=a.Event("hide.bs.dropdown",f)),b.isDefaultPrevented()||(d.attr("aria-expanded","false"),e.removeClass("open").trigger("hidden.bs.dropdown",f)))}))}function c(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}function d(b){return this.each(function(){var c=a(this),d=c.data("bs.dropdown");d||c.data("bs.dropdown",d=new g(this)),"string"==typeof b&&d[b].call(c)})}var e=".dropdown-backdrop",f='[data-toggle="dropdown"]',g=function(b){a(b).on("click.bs.dropdown",this.toggle)};g.VERSION="3.3.1",g.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=c(e),g=f.hasClass("open");if(b(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a('<div class="dropdown-backdrop"/>').insertAfter(a(this)).on("click",b);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;e.trigger("focus").attr("aria-expanded","true"),f.toggleClass("open").trigger("shown.bs.dropdown",h)}return!1}},g.prototype.keydown=function(b){if(/(38|40|27|32)/.test(b.which)&&!/input|textarea/i.test(b.target.tagName)){var d=a(this);if(b.preventDefault(),b.stopPropagation(),!d.is(".disabled, :disabled")){var e=c(d),g=e.hasClass("open");if(!g&&27!=b.which||g&&27==b.which)return 27==b.which&&e.find(f).trigger("focus"),d.trigger("click");var h=" li:not(.divider):visible a",i=e.find('[role="menu"]'+h+', [role="listbox"]'+h);if(i.length){var j=i.index(b.target);38==b.which&&j>0&&j--,40==b.which&&j<i.length-1&&j++,~j||(j=0),i.eq(j).trigger("focus")}}}};var h=a.fn.dropdown;a.fn.dropdown=d,a.fn.dropdown.Constructor=g,a.fn.dropdown.noConflict=function(){return a.fn.dropdown=h,this},a(document).on("click.bs.dropdown.data-api",b).on("click.bs.dropdown.data-api",".dropdown form",function(a){a.stopPropagation()}).on("click.bs.dropdown.data-api",f,g.prototype.toggle).on("keydown.bs.dropdown.data-api",f,g.prototype.keydown).on("keydown.bs.dropdown.data-api",'[role="menu"]',g.prototype.keydown).on("keydown.bs.dropdown.data-api",'[role="listbox"]',g.prototype.keydown)}(jQuery),+function(a){"use strict";function b(b,d){return this.each(function(){var e=a(this),f=e.data("bs.modal"),g=a.extend({},c.DEFAULTS,e.data(),"object"==typeof b&&b);f||e.data("bs.modal",f=new c(this,g)),"string"==typeof b?f[b](d):g.show&&f.show(d)})}var c=function(b,c){this.options=c,this.$body=a(document.body),this.$element=a(b),this.$backdrop=this.isShown=null,this.scrollbarWidth=0,this.options.remote&&this.$element.find(".modal-content").load(this.options.remote,a.proxy(function(){this.$element.trigger("loaded.bs.modal")},this))};c.VERSION="3.3.1",c.TRANSITION_DURATION=300,c.BACKDROP_TRANSITION_DURATION=150,c.DEFAULTS={backdrop:!0,keyboard:!0,show:!0},c.prototype.toggle=function(a){return this.isShown?this.hide():this.show(a)},c.prototype.show=function(b){var d=this,e=a.Event("show.bs.modal",{relatedTarget:b});this.$element.trigger(e),this.isShown||e.isDefaultPrevented()||(this.isShown=!0,this.checkScrollbar(),this.setScrollbar(),this.$body.addClass("modal-open"),this.escape(),this.resize(),this.$element.on("click.dismiss.bs.modal",'[data-dismiss="modal"]',a.proxy(this.hide,this)),this.backdrop(function(){var e=a.support.transition&&d.$element.hasClass("fade");d.$element.parent().length||d.$element.appendTo(d.$body),d.$element.show().scrollTop(0),d.options.backdrop&&d.adjustBackdrop(),d.adjustDialog(),e&&d.$element[0].offsetWidth,d.$element.addClass("in").attr("aria-hidden",!1),d.enforceFocus();var f=a.Event("shown.bs.modal",{relatedTarget:b});e?d.$element.find(".modal-dialog").one("bsTransitionEnd",function(){d.$element.trigger("focus").trigger(f)}).emulateTransitionEnd(c.TRANSITION_DURATION):d.$element.trigger("focus").trigger(f)}))},c.prototype.hide=function(b){b&&b.preventDefault(),b=a.Event("hide.bs.modal"),this.$element.trigger(b),this.isShown&&!b.isDefaultPrevented()&&(this.isShown=!1,this.escape(),this.resize(),a(document).off("focusin.bs.modal"),this.$element.removeClass("in").attr("aria-hidden",!0).off("click.dismiss.bs.modal"),a.support.transition&&this.$element.hasClass("fade")?this.$element.one("bsTransitionEnd",a.proxy(this.hideModal,this)).emulateTransitionEnd(c.TRANSITION_DURATION):this.hideModal())},c.prototype.enforceFocus=function(){a(document).off("focusin.bs.modal").on("focusin.bs.modal",a.proxy(function(a){this.$element[0]===a.target||this.$element.has(a.target).length||this.$element.trigger("focus")},this))},c.prototype.escape=function(){this.isShown&&this.options.keyboard?this.$element.on("keydown.dismiss.bs.modal",a.proxy(function(a){27==a.which&&this.hide()},this)):this.isShown||this.$element.off("keydown.dismiss.bs.modal")},c.prototype.resize=function(){this.isShown?a(window).on("resize.bs.modal",a.proxy(this.handleUpdate,this)):a(window).off("resize.bs.modal")},c.prototype.hideModal=function(){var a=this;this.$element.hide(),this.backdrop(function(){a.$body.removeClass("modal-open"),a.resetAdjustments(),a.resetScrollbar(),a.$element.trigger("hidden.bs.modal")})},c.prototype.removeBackdrop=function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},c.prototype.backdrop=function(b){var d=this,e=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var f=a.support.transition&&e;if(this.$backdrop=a('<div class="modal-backdrop '+e+'" />').prependTo(this.$element).on("click.dismiss.bs.modal",a.proxy(function(a){a.target===a.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus.call(this.$element[0]):this.hide.call(this))},this)),f&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!b)return;f?this.$backdrop.one("bsTransitionEnd",b).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION):b()}else if(!this.isShown&&this.$backdrop){this.$backdrop.removeClass("in");var g=function(){d.removeBackdrop(),b&&b()};a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",g).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION):g()}else b&&b()},c.prototype.handleUpdate=function(){this.options.backdrop&&this.adjustBackdrop(),this.adjustDialog()},c.prototype.adjustBackdrop=function(){this.$backdrop.css("height",0).css("height",this.$element[0].scrollHeight)},c.prototype.adjustDialog=function(){var a=this.$element[0].scrollHeight>document.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&a?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!a?this.scrollbarWidth:""})},c.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},c.prototype.checkScrollbar=function(){this.bodyIsOverflowing=document.body.scrollHeight>document.documentElement.clientHeight,this.scrollbarWidth=this.measureScrollbar()},c.prototype.setScrollbar=function(){var a=parseInt(this.$body.css("padding-right")||0,10);this.bodyIsOverflowing&&this.$body.css("padding-right",a+this.scrollbarWidth)},c.prototype.resetScrollbar=function(){this.$body.css("padding-right","")},c.prototype.measureScrollbar=function(){var a=document.createElement("div");a.className="modal-scrollbar-measure",this.$body.append(a);var b=a.offsetWidth-a.clientWidth;return this.$body[0].removeChild(a),b};var d=a.fn.modal;a.fn.modal=b,a.fn.modal.Constructor=c,a.fn.modal.noConflict=function(){return a.fn.modal=d,this},a(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(c){var d=a(this),e=d.attr("href"),f=a(d.attr("data-target")||e&&e.replace(/.*(?=#[^\s]+$)/,"")),g=f.data("bs.modal")?"toggle":a.extend({remote:!/#/.test(e)&&e},f.data(),d.data());d.is("a")&&c.preventDefault(),f.one("show.bs.modal",function(a){a.isDefaultPrevented()||f.one("hidden.bs.modal",function(){d.is(":visible")&&d.trigger("focus")})}),b.call(f,g,this)})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tooltip"),f="object"==typeof b&&b,g=f&&f.selector;(e||"destroy"!=b)&&(g?(e||d.data("bs.tooltip",e={}),e[g]||(e[g]=new c(this,f))):e||d.data("bs.tooltip",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.type=this.options=this.enabled=this.timeout=this.hoverState=this.$element=null,this.init("tooltip",a,b)};c.VERSION="3.3.1",c.TRANSITION_DURATION=150,c.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},c.prototype.init=function(b,c,d){this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.$viewport=this.options.viewport&&a(this.options.viewport.selector||this.options.viewport);for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},c.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},c.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c&&c.$tip&&c.$tip.is(":visible")?void(c.hoverState="in"):(c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show())},c.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide()},c.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(b);var d=a.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(b.isDefaultPrevented()||!d)return;var e=this,f=this.tip(),g=this.getUID(this.type);this.setContent(),f.attr("id",g),this.$element.attr("aria-describedby",g),this.options.animation&&f.addClass("fade");var h="function"==typeof this.options.placement?this.options.placement.call(this,f[0],this.$element[0]):this.options.placement,i=/\s?auto?\s?/i,j=i.test(h);j&&(h=h.replace(i,"")||"top"),f.detach().css({top:0,left:0,display:"block"}).addClass(h).data("bs."+this.type,this),this.options.container?f.appendTo(this.options.container):f.insertAfter(this.$element);var k=this.getPosition(),l=f[0].offsetWidth,m=f[0].offsetHeight;if(j){var n=h,o=this.options.container?a(this.options.container):this.$element.parent(),p=this.getPosition(o);h="bottom"==h&&k.bottom+m>p.bottom?"top":"top"==h&&k.top-m<p.top?"bottom":"right"==h&&k.right+l>p.width?"left":"left"==h&&k.left-l<p.left?"right":h,f.removeClass(n).addClass(h)}var q=this.getCalculatedOffset(h,k,l,m);this.applyPlacement(q,h);var r=function(){var a=e.hoverState;e.$element.trigger("shown.bs."+e.type),e.hoverState=null,"out"==a&&e.leave(e)};a.support.transition&&this.$tip.hasClass("fade")?f.one("bsTransitionEnd",r).emulateTransitionEnd(c.TRANSITION_DURATION):r()}},c.prototype.applyPlacement=function(b,c){var d=this.tip(),e=d[0].offsetWidth,f=d[0].offsetHeight,g=parseInt(d.css("margin-top"),10),h=parseInt(d.css("margin-left"),10);isNaN(g)&&(g=0),isNaN(h)&&(h=0),b.top=b.top+g,b.left=b.left+h,a.offset.setOffset(d[0],a.extend({using:function(a){d.css({top:Math.round(a.top),left:Math.round(a.left)})}},b),0),d.addClass("in");var i=d[0].offsetWidth,j=d[0].offsetHeight;"top"==c&&j!=f&&(b.top=b.top+f-j);var k=this.getViewportAdjustedDelta(c,b,i,j);k.left?b.left+=k.left:b.top+=k.top;var l=/top|bottom/.test(c),m=l?2*k.left-e+i:2*k.top-f+j,n=l?"offsetWidth":"offsetHeight";d.offset(b),this.replaceArrow(m,d[0][n],l)},c.prototype.replaceArrow=function(a,b,c){this.arrow().css(c?"left":"top",50*(1-a/b)+"%").css(c?"top":"left","")},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle();a.find(".tooltip-inner")[this.options.html?"html":"text"](b),a.removeClass("fade in top bottom left right")},c.prototype.hide=function(b){function d(){"in"!=e.hoverState&&f.detach(),e.$element.removeAttr("aria-describedby").trigger("hidden.bs."+e.type),b&&b()}var e=this,f=this.tip(),g=a.Event("hide.bs."+this.type);return this.$element.trigger(g),g.isDefaultPrevented()?void 0:(f.removeClass("in"),a.support.transition&&this.$tip.hasClass("fade")?f.one("bsTransitionEnd",d).emulateTransitionEnd(c.TRANSITION_DURATION):d(),this.hoverState=null,this)},c.prototype.fixTitle=function(){var a=this.$element;(a.attr("title")||"string"!=typeof a.attr("data-original-title"))&&a.attr("data-original-title",a.attr("title")||"").attr("title","")},c.prototype.hasContent=function(){return this.getTitle()},c.prototype.getPosition=function(b){b=b||this.$element;var c=b[0],d="BODY"==c.tagName,e=c.getBoundingClientRect();null==e.width&&(e=a.extend({},e,{width:e.right-e.left,height:e.bottom-e.top}));var f=d?{top:0,left:0}:b.offset(),g={scroll:d?document.documentElement.scrollTop||document.body.scrollTop:b.scrollTop()},h=d?{width:a(window).width(),height:a(window).height()}:null;return a.extend({},e,g,h,f)},c.prototype.getCalculatedOffset=function(a,b,c,d){return"bottom"==a?{top:b.top+b.height,left:b.left+b.width/2-c/2}:"top"==a?{top:b.top-d,left:b.left+b.width/2-c/2}:"left"==a?{top:b.top+b.height/2-d/2,left:b.left-c}:{top:b.top+b.height/2-d/2,left:b.left+b.width}},c.prototype.getViewportAdjustedDelta=function(a,b,c,d){var e={top:0,left:0};if(!this.$viewport)return e;var f=this.options.viewport&&this.options.viewport.padding||0,g=this.getPosition(this.$viewport);if(/right|left/.test(a)){var h=b.top-f-g.scroll,i=b.top+f-g.scroll+d;h<g.top?e.top=g.top-h:i>g.top+g.height&&(e.top=g.top+g.height-i)}else{var j=b.left-f,k=b.left+f+c;j<g.left?e.left=g.left-j:k>g.width&&(e.left=g.left+g.width-k)}return e},c.prototype.getTitle=function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||("function"==typeof c.title?c.title.call(b[0]):c.title)},c.prototype.getUID=function(a){do a+=~~(1e6*Math.random());while(document.getElementById(a));return a},c.prototype.tip=function(){return this.$tip=this.$tip||a(this.options.template)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},c.prototype.enable=function(){this.enabled=!0},c.prototype.disable=function(){this.enabled=!1},c.prototype.toggleEnabled=function(){this.enabled=!this.enabled},c.prototype.toggle=function(b){var c=this;b&&(c=a(b.currentTarget).data("bs."+this.type),c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c))),c.tip().hasClass("in")?c.leave(c):c.enter(c)},c.prototype.destroy=function(){var a=this;clearTimeout(this.timeout),this.hide(function(){a.$element.off("."+a.type).removeData("bs."+a.type)})};var d=a.fn.tooltip;a.fn.tooltip=b,a.fn.tooltip.Constructor=c,a.fn.tooltip.noConflict=function(){return a.fn.tooltip=d,this}}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof b&&b,g=f&&f.selector;(e||"destroy"!=b)&&(g?(e||d.data("bs.popover",e={}),e[g]||(e[g]=new c(this,f))):e||d.data("bs.popover",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.init("popover",a,b)};if(!a.fn.tooltip)throw new Error("Popover requires tooltip.js");c.VERSION="3.3.1",c.DEFAULTS=a.extend({},a.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),c.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),c.prototype.constructor=c,c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content").children().detach().end()[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},c.prototype.hasContent=function(){return this.getTitle()||this.getContent()},c.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")},c.prototype.tip=function(){return this.$tip||(this.$tip=a(this.options.template)),this.$tip};var d=a.fn.popover;a.fn.popover=b,a.fn.popover.Constructor=c,a.fn.popover.noConflict=function(){return a.fn.popover=d,this}}(jQuery),+function(a){"use strict";function b(c,d){var e=a.proxy(this.process,this);this.$body=a("body"),this.$scrollElement=a(a(c).is("body")?window:c),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",e),this.refresh(),this.process()}function c(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})}b.VERSION="3.3.1",b.DEFAULTS={offset:10},b.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},b.prototype.refresh=function(){var b="offset",c=0;a.isWindow(this.$scrollElement[0])||(b="position",c=this.$scrollElement.scrollTop()),this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight();var d=this;this.$body.find(this.selector).map(function(){var d=a(this),e=d.data("target")||d.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[b]().top+c,e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){d.offsets.push(this[0]),d.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.getScrollHeight(),d=this.options.offset+c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(this.scrollHeight!=c&&this.refresh(),b>=d)return g!=(a=f[f.length-1])&&this.activate(a);if(g&&b<e[0])return this.activeTarget=null,this.clear();for(a=e.length;a--;)g!=f[a]&&b>=e[a]&&(!e[a+1]||b<=e[a+1])&&this.activate(f[a])},b.prototype.activate=function(b){this.activeTarget=b,this.clear();var c=this.selector+'[data-target="'+b+'"],'+this.selector+'[href="'+b+'"]',d=a(c).parents("li").addClass("active");d.parent(".dropdown-menu").length&&(d=d.closest("li.dropdown").addClass("active")),d.trigger("activate.bs.scrollspy")},b.prototype.clear=function(){a(this.selector).parentsUntil(this.options.target,".active").removeClass("active")};var d=a.fn.scrollspy;a.fn.scrollspy=c,a.fn.scrollspy.Constructor=b,a.fn.scrollspy.noConflict=function(){return a.fn.scrollspy=d,this},a(window).on("load.bs.scrollspy.data-api",function(){a('[data-spy="scroll"]').each(function(){var b=a(this);c.call(b,b.data())})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tab");e||d.data("bs.tab",e=new c(this)),"string"==typeof b&&e[b]()})}var c=function(b){this.element=a(b)};c.VERSION="3.3.1",c.TRANSITION_DURATION=150,c.prototype.show=function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.data("target");if(d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),!b.parent("li").hasClass("active")){var e=c.find(".active:last a"),f=a.Event("hide.bs.tab",{relatedTarget:b[0]}),g=a.Event("show.bs.tab",{relatedTarget:e[0]});if(e.trigger(f),b.trigger(g),!g.isDefaultPrevented()&&!f.isDefaultPrevented()){var h=a(d);this.activate(b.closest("li"),c),this.activate(h,h.parent(),function(){e.trigger({type:"hidden.bs.tab",relatedTarget:b[0]}),b.trigger({type:"shown.bs.tab",relatedTarget:e[0]}) +})}}},c.prototype.activate=function(b,d,e){function f(){g.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),b.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),h?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu")&&b.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),e&&e()}var g=d.find("> .active"),h=e&&a.support.transition&&(g.length&&g.hasClass("fade")||!!d.find("> .fade").length);g.length&&h?g.one("bsTransitionEnd",f).emulateTransitionEnd(c.TRANSITION_DURATION):f(),g.removeClass("in")};var d=a.fn.tab;a.fn.tab=b,a.fn.tab.Constructor=c,a.fn.tab.noConflict=function(){return a.fn.tab=d,this};var e=function(c){c.preventDefault(),b.call(a(this),"show")};a(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',e).on("click.bs.tab.data-api",'[data-toggle="pill"]',e)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof b&&b;e||d.data("bs.affix",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.options=a.extend({},c.DEFAULTS,d),this.$target=a(this.options.target).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(b),this.affixed=this.unpin=this.pinnedOffset=null,this.checkPosition()};c.VERSION="3.3.1",c.RESET="affix affix-top affix-bottom",c.DEFAULTS={offset:0,target:window},c.prototype.getState=function(a,b,c,d){var e=this.$target.scrollTop(),f=this.$element.offset(),g=this.$target.height();if(null!=c&&"top"==this.affixed)return c>e?"top":!1;if("bottom"==this.affixed)return null!=c?e+this.unpin<=f.top?!1:"bottom":a-d>=e+g?!1:"bottom";var h=null==this.affixed,i=h?e:f.top,j=h?g:b;return null!=c&&c>=i?"top":null!=d&&i+j>=a-d?"bottom":!1},c.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(c.RESET).addClass("affix");var a=this.$target.scrollTop(),b=this.$element.offset();return this.pinnedOffset=b.top-a},c.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},c.prototype.checkPosition=function(){if(this.$element.is(":visible")){var b=this.$element.height(),d=this.options.offset,e=d.top,f=d.bottom,g=a("body").height();"object"!=typeof d&&(f=e=d),"function"==typeof e&&(e=d.top(this.$element)),"function"==typeof f&&(f=d.bottom(this.$element));var h=this.getState(g,b,e,f);if(this.affixed!=h){null!=this.unpin&&this.$element.css("top","");var i="affix"+(h?"-"+h:""),j=a.Event(i+".bs.affix");if(this.$element.trigger(j),j.isDefaultPrevented())return;this.affixed=h,this.unpin="bottom"==h?this.getPinnedOffset():null,this.$element.removeClass(c.RESET).addClass(i).trigger(i.replace("affix","affixed")+".bs.affix")}"bottom"==h&&this.$element.offset({top:g-b-f})}};var d=a.fn.affix;a.fn.affix=b,a.fn.affix.Constructor=c,a.fn.affix.noConflict=function(){return a.fn.affix=d,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var c=a(this),d=c.data();d.offset=d.offset||{},null!=d.offsetBottom&&(d.offset.bottom=d.offsetBottom),null!=d.offsetTop&&(d.offset.top=d.offsetTop),b.call(c,d)})})}(jQuery);</script> + <script>/*! markdown-it 11.0.0 https://github.com//markdown-it/markdown-it @license MIT */!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).markdownit=e()}}((function(){return function e(r,t,n){function s(i,a){if(!t[i]){if(!r[i]){var c="function"==typeof require&&require;if(!a&&c)return c(i,!0);if(o)return o(i,!0);var l=new Error("Cannot find module '"+i+"'");throw l.code="MODULE_NOT_FOUND",l}var u=t[i]={exports:{}};r[i][0].call(u.exports,(function(e){return s(r[i][1][e]||e)}),u,u.exports,e,r,t,n)}return t[i].exports}for(var o="function"==typeof require&&require,i=0;i<n.length;i++)s(n[i]);return s}({1:[function(e,r,t){"use strict";r.exports=e("entities/lib/maps/entities.json")},{"entities/lib/maps/entities.json":52}],2:[function(e,r,t){"use strict";r.exports=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","meta","nav","noframes","ol","optgroup","option","p","param","section","source","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"]},{}],3:[function(e,r,t){"use strict";var n="<[A-Za-z][A-Za-z0-9\\-]*(?:\\s+[a-zA-Z_:][a-zA-Z0-9:._-]*(?:\\s*=\\s*(?:[^\"'=<>`\\x00-\\x20]+|'[^']*'|\"[^\"]*\"))?)*\\s*\\/?>",s="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",o=new RegExp("^(?:"+n+"|"+s+"|\x3c!----\x3e|\x3c!--(?:-?[^>-])(?:-?[^-])*--\x3e|<[?].*?[?]>|<![A-Z]+\\s+[^>]*>|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>)"),i=new RegExp("^(?:"+n+"|"+s+")");r.exports.HTML_TAG_RE=o,r.exports.HTML_OPEN_CLOSE_TAG_RE=i},{}],4:[function(e,r,t){"use strict";var n=Object.prototype.hasOwnProperty;function s(e,r){return n.call(e,r)}function o(e){return!(e>=55296&&e<=57343)&&(!(e>=64976&&e<=65007)&&(65535!=(65535&e)&&65534!=(65535&e)&&(!(e>=0&&e<=8)&&(11!==e&&(!(e>=14&&e<=31)&&(!(e>=127&&e<=159)&&!(e>1114111)))))))}function i(e){if(e>65535){var r=55296+((e-=65536)>>10),t=56320+(1023&e);return String.fromCharCode(r,t)}return String.fromCharCode(e)}var a=/\\([!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~])/g,c=new RegExp(a.source+"|"+/&([a-z#][a-z0-9]{1,31});/gi.source,"gi"),l=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))/i,u=e("./entities");var p=/[&<>"]/,h=/[&<>"]/g,f={"&":"&","<":"<",">":">",'"':"""};function d(e){return f[e]}var m=/[.?*+^$[\]\\(){}|-]/g;var _=e("uc.micro/categories/P/regex");t.lib={},t.lib.mdurl=e("mdurl"),t.lib.ucmicro=e("uc.micro"),t.assign=function(e){var r=Array.prototype.slice.call(arguments,1);return r.forEach((function(r){if(r){if("object"!=typeof r)throw new TypeError(r+"must be object");Object.keys(r).forEach((function(t){e[t]=r[t]}))}})),e},t.isString=function(e){return"[object String]"===function(e){return Object.prototype.toString.call(e)}(e)},t.has=s,t.unescapeMd=function(e){return e.indexOf("\\")<0?e:e.replace(a,"$1")},t.unescapeAll=function(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(c,(function(e,r,t){return r||function(e,r){var t=0;return s(u,r)?u[r]:35===r.charCodeAt(0)&&l.test(r)&&o(t="x"===r[1].toLowerCase()?parseInt(r.slice(2),16):parseInt(r.slice(1),10))?i(t):e}(e,t)}))},t.isValidEntityCode=o,t.fromCodePoint=i,t.escapeHtml=function(e){return p.test(e)?e.replace(h,d):e},t.arrayReplaceAt=function(e,r,t){return[].concat(e.slice(0,r),t,e.slice(r+1))},t.isSpace=function(e){switch(e){case 9:case 32:return!0}return!1},t.isWhiteSpace=function(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1},t.isMdAsciiPunct=function(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}},t.isPunctChar=function(e){return _.test(e)},t.escapeRE=function(e){return e.replace(m,"\\$&")},t.normalizeReference=function(e){return e=e.trim().replace(/\s+/g," "),"\u1e7e"==="\u1e9e".toLowerCase()&&(e=e.replace(/\u1e9e/g,"\xdf")),e.toLowerCase().toUpperCase()}},{"./entities":1,mdurl:58,"uc.micro":65,"uc.micro/categories/P/regex":63}],5:[function(e,r,t){"use strict";t.parseLinkLabel=e("./parse_link_label"),t.parseLinkDestination=e("./parse_link_destination"),t.parseLinkTitle=e("./parse_link_title")},{"./parse_link_destination":6,"./parse_link_label":7,"./parse_link_title":8}],6:[function(e,r,t){"use strict";var n=e("../common/utils").unescapeAll;r.exports=function(e,r,t){var s,o,i=r,a={ok:!1,pos:0,lines:0,str:""};if(60===e.charCodeAt(r)){for(r++;r<t;){if(10===(s=e.charCodeAt(r)))return a;if(62===s)return a.pos=r+1,a.str=n(e.slice(i+1,r)),a.ok=!0,a;92===s&&r+1<t?r+=2:r++}return a}for(o=0;r<t&&32!==(s=e.charCodeAt(r))&&!(s<32||127===s);)if(92===s&&r+1<t)r+=2;else{if(40===s&&o++,41===s){if(0===o)break;o--}r++}return i===r||0!==o||(a.str=n(e.slice(i,r)),a.lines=0,a.pos=r,a.ok=!0),a}},{"../common/utils":4}],7:[function(e,r,t){"use strict";r.exports=function(e,r,t){var n,s,o,i,a=-1,c=e.posMax,l=e.pos;for(e.pos=r+1,n=1;e.pos<c;){if(93===(o=e.src.charCodeAt(e.pos))&&0===--n){s=!0;break}if(i=e.pos,e.md.inline.skipToken(e),91===o)if(i===e.pos-1)n++;else if(t)return e.pos=l,-1}return s&&(a=e.pos),e.pos=l,a}},{}],8:[function(e,r,t){"use strict";var n=e("../common/utils").unescapeAll;r.exports=function(e,r,t){var s,o,i=0,a=r,c={ok:!1,pos:0,lines:0,str:""};if(r>=t)return c;if(34!==(o=e.charCodeAt(r))&&39!==o&&40!==o)return c;for(r++,40===o&&(o=41);r<t;){if((s=e.charCodeAt(r))===o)return c.pos=r+1,c.lines=i,c.str=n(e.slice(a+1,r)),c.ok=!0,c;10===s?i++:92===s&&r+1<t&&(r++,10===e.charCodeAt(r)&&i++),r++}return c}},{"../common/utils":4}],9:[function(e,r,t){"use strict";var n=e("./common/utils"),s=e("./helpers"),o=e("./renderer"),i=e("./parser_core"),a=e("./parser_block"),c=e("./parser_inline"),l=e("linkify-it"),u=e("mdurl"),p=e("punycode"),h={default:e("./presets/default"),zero:e("./presets/zero"),commonmark:e("./presets/commonmark")},f=/^(vbscript|javascript|file|data):/,d=/^data:image\/(gif|png|jpeg|webp);/;function m(e){var r=e.trim().toLowerCase();return!f.test(r)||!!d.test(r)}var _=["http:","https:","mailto:"];function g(e){var r=u.parse(e,!0);if(r.hostname&&(!r.protocol||_.indexOf(r.protocol)>=0))try{r.hostname=p.toASCII(r.hostname)}catch(e){}return u.encode(u.format(r))}function k(e){var r=u.parse(e,!0);if(r.hostname&&(!r.protocol||_.indexOf(r.protocol)>=0))try{r.hostname=p.toUnicode(r.hostname)}catch(e){}return u.decode(u.format(r))}function b(e,r){if(!(this instanceof b))return new b(e,r);r||n.isString(e)||(r=e||{},e="default"),this.inline=new c,this.block=new a,this.core=new i,this.renderer=new o,this.linkify=new l,this.validateLink=m,this.normalizeLink=g,this.normalizeLinkText=k,this.utils=n,this.helpers=n.assign({},s),this.options={},this.configure(e),r&&this.set(r)}b.prototype.set=function(e){return n.assign(this.options,e),this},b.prototype.configure=function(e){var r,t=this;if(n.isString(e)&&!(e=h[r=e]))throw new Error('Wrong `markdown-it` preset "'+r+'", check name');if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach((function(r){e.components[r].rules&&t[r].ruler.enableOnly(e.components[r].rules),e.components[r].rules2&&t[r].ruler2.enableOnly(e.components[r].rules2)})),this},b.prototype.enable=function(e,r){var t=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach((function(r){t=t.concat(this[r].ruler.enable(e,!0))}),this),t=t.concat(this.inline.ruler2.enable(e,!0));var n=e.filter((function(e){return t.indexOf(e)<0}));if(n.length&&!r)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+n);return this},b.prototype.disable=function(e,r){var t=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach((function(r){t=t.concat(this[r].ruler.disable(e,!0))}),this),t=t.concat(this.inline.ruler2.disable(e,!0));var n=e.filter((function(e){return t.indexOf(e)<0}));if(n.length&&!r)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+n);return this},b.prototype.use=function(e){var r=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,r),this},b.prototype.parse=function(e,r){if("string"!=typeof e)throw new Error("Input data should be a String");var t=new this.core.State(e,this,r);return this.core.process(t),t.tokens},b.prototype.render=function(e,r){return r=r||{},this.renderer.render(this.parse(e,r),this.options,r)},b.prototype.parseInline=function(e,r){var t=new this.core.State(e,this,r);return t.inlineMode=!0,this.core.process(t),t.tokens},b.prototype.renderInline=function(e,r){return r=r||{},this.renderer.render(this.parseInline(e,r),this.options,r)},r.exports=b},{"./common/utils":4,"./helpers":5,"./parser_block":10,"./parser_core":11,"./parser_inline":12,"./presets/commonmark":13,"./presets/default":14,"./presets/zero":15,"./renderer":16,"linkify-it":53,mdurl:58,punycode:60}],10:[function(e,r,t){"use strict";var n=e("./ruler"),s=[["table",e("./rules_block/table"),["paragraph","reference"]],["code",e("./rules_block/code")],["fence",e("./rules_block/fence"),["paragraph","reference","blockquote","list"]],["blockquote",e("./rules_block/blockquote"),["paragraph","reference","blockquote","list"]],["hr",e("./rules_block/hr"),["paragraph","reference","blockquote","list"]],["list",e("./rules_block/list"),["paragraph","reference","blockquote"]],["reference",e("./rules_block/reference")],["heading",e("./rules_block/heading"),["paragraph","reference","blockquote"]],["lheading",e("./rules_block/lheading")],["html_block",e("./rules_block/html_block"),["paragraph","reference","blockquote"]],["paragraph",e("./rules_block/paragraph")]];function o(){this.ruler=new n;for(var e=0;e<s.length;e++)this.ruler.push(s[e][0],s[e][1],{alt:(s[e][2]||[]).slice()})}o.prototype.tokenize=function(e,r,t){for(var n,s=this.ruler.getRules(""),o=s.length,i=r,a=!1,c=e.md.options.maxNesting;i<t&&(e.line=i=e.skipEmptyLines(i),!(i>=t))&&!(e.sCount[i]<e.blkIndent);){if(e.level>=c){e.line=t;break}for(n=0;n<o&&!s[n](e,i,t,!1);n++);e.tight=!a,e.isEmpty(e.line-1)&&(a=!0),(i=e.line)<t&&e.isEmpty(i)&&(a=!0,i++,e.line=i)}},o.prototype.parse=function(e,r,t,n){var s;e&&(s=new this.State(e,r,t,n),this.tokenize(s,s.line,s.lineMax))},o.prototype.State=e("./rules_block/state_block"),r.exports=o},{"./ruler":17,"./rules_block/blockquote":18,"./rules_block/code":19,"./rules_block/fence":20,"./rules_block/heading":21,"./rules_block/hr":22,"./rules_block/html_block":23,"./rules_block/lheading":24,"./rules_block/list":25,"./rules_block/paragraph":26,"./rules_block/reference":27,"./rules_block/state_block":28,"./rules_block/table":29}],11:[function(e,r,t){"use strict";var n=e("./ruler"),s=[["normalize",e("./rules_core/normalize")],["block",e("./rules_core/block")],["inline",e("./rules_core/inline")],["linkify",e("./rules_core/linkify")],["replacements",e("./rules_core/replacements")],["smartquotes",e("./rules_core/smartquotes")]];function o(){this.ruler=new n;for(var e=0;e<s.length;e++)this.ruler.push(s[e][0],s[e][1])}o.prototype.process=function(e){var r,t,n;for(r=0,t=(n=this.ruler.getRules("")).length;r<t;r++)n[r](e)},o.prototype.State=e("./rules_core/state_core"),r.exports=o},{"./ruler":17,"./rules_core/block":30,"./rules_core/inline":31,"./rules_core/linkify":32,"./rules_core/normalize":33,"./rules_core/replacements":34,"./rules_core/smartquotes":35,"./rules_core/state_core":36}],12:[function(e,r,t){"use strict";var n=e("./ruler"),s=[["text",e("./rules_inline/text")],["newline",e("./rules_inline/newline")],["escape",e("./rules_inline/escape")],["backticks",e("./rules_inline/backticks")],["strikethrough",e("./rules_inline/strikethrough").tokenize],["emphasis",e("./rules_inline/emphasis").tokenize],["link",e("./rules_inline/link")],["image",e("./rules_inline/image")],["autolink",e("./rules_inline/autolink")],["html_inline",e("./rules_inline/html_inline")],["entity",e("./rules_inline/entity")]],o=[["balance_pairs",e("./rules_inline/balance_pairs")],["strikethrough",e("./rules_inline/strikethrough").postProcess],["emphasis",e("./rules_inline/emphasis").postProcess],["text_collapse",e("./rules_inline/text_collapse")]];function i(){var e;for(this.ruler=new n,e=0;e<s.length;e++)this.ruler.push(s[e][0],s[e][1]);for(this.ruler2=new n,e=0;e<o.length;e++)this.ruler2.push(o[e][0],o[e][1])}i.prototype.skipToken=function(e){var r,t,n=e.pos,s=this.ruler.getRules(""),o=s.length,i=e.md.options.maxNesting,a=e.cache;if(void 0===a[n]){if(e.level<i)for(t=0;t<o&&(e.level++,r=s[t](e,!0),e.level--,!r);t++);else e.pos=e.posMax;r||e.pos++,a[n]=e.pos}else e.pos=a[n]},i.prototype.tokenize=function(e){for(var r,t,n=this.ruler.getRules(""),s=n.length,o=e.posMax,i=e.md.options.maxNesting;e.pos<o;){if(e.level<i)for(t=0;t<s&&!(r=n[t](e,!1));t++);if(r){if(e.pos>=o)break}else e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},i.prototype.parse=function(e,r,t,n){var s,o,i,a=new this.State(e,r,t,n);for(this.tokenize(a),i=(o=this.ruler2.getRules("")).length,s=0;s<i;s++)o[s](a)},i.prototype.State=e("./rules_inline/state_inline"),r.exports=i},{"./ruler":17,"./rules_inline/autolink":37,"./rules_inline/backticks":38,"./rules_inline/balance_pairs":39,"./rules_inline/emphasis":40,"./rules_inline/entity":41,"./rules_inline/escape":42,"./rules_inline/html_inline":43,"./rules_inline/image":44,"./rules_inline/link":45,"./rules_inline/newline":46,"./rules_inline/state_inline":47,"./rules_inline/strikethrough":48,"./rules_inline/text":49,"./rules_inline/text_collapse":50}],13:[function(e,r,t){"use strict";r.exports={options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"],rules2:["balance_pairs","emphasis","text_collapse"]}}}},{}],14:[function(e,r,t){"use strict";r.exports={options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:100},components:{core:{},block:{},inline:{}}}},{}],15:[function(e,r,t){"use strict";r.exports={options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["paragraph"]},inline:{rules:["text"],rules2:["balance_pairs","text_collapse"]}}}},{}],16:[function(e,r,t){"use strict";var n=e("./common/utils").assign,s=e("./common/utils").unescapeAll,o=e("./common/utils").escapeHtml,i={};function a(){this.rules=n({},i)}i.code_inline=function(e,r,t,n,s){var i=e[r];return"<code"+s.renderAttrs(i)+">"+o(e[r].content)+"</code>"},i.code_block=function(e,r,t,n,s){var i=e[r];return"<pre"+s.renderAttrs(i)+"><code>"+o(e[r].content)+"</code></pre>\n"},i.fence=function(e,r,t,n,i){var a,c,l,u,p=e[r],h=p.info?s(p.info).trim():"",f="";return h&&(f=h.split(/\s+/g)[0]),0===(a=t.highlight&&t.highlight(p.content,f)||o(p.content)).indexOf("<pre")?a+"\n":h?(c=p.attrIndex("class"),l=p.attrs?p.attrs.slice():[],c<0?l.push(["class",t.langPrefix+f]):l[c][1]+=" "+t.langPrefix+f,u={attrs:l},"<pre><code"+i.renderAttrs(u)+">"+a+"</code></pre>\n"):"<pre><code"+i.renderAttrs(p)+">"+a+"</code></pre>\n"},i.image=function(e,r,t,n,s){var o=e[r];return o.attrs[o.attrIndex("alt")][1]=s.renderInlineAsText(o.children,t,n),s.renderToken(e,r,t)},i.hardbreak=function(e,r,t){return t.xhtmlOut?"<br />\n":"<br>\n"},i.softbreak=function(e,r,t){return t.breaks?t.xhtmlOut?"<br />\n":"<br>\n":"\n"},i.text=function(e,r){return o(e[r].content)},i.html_block=function(e,r){return e[r].content},i.html_inline=function(e,r){return e[r].content},a.prototype.renderAttrs=function(e){var r,t,n;if(!e.attrs)return"";for(n="",r=0,t=e.attrs.length;r<t;r++)n+=" "+o(e.attrs[r][0])+'="'+o(e.attrs[r][1])+'"';return n},a.prototype.renderToken=function(e,r,t){var n,s="",o=!1,i=e[r];return i.hidden?"":(i.block&&-1!==i.nesting&&r&&e[r-1].hidden&&(s+="\n"),s+=(-1===i.nesting?"</":"<")+i.tag,s+=this.renderAttrs(i),0===i.nesting&&t.xhtmlOut&&(s+=" /"),i.block&&(o=!0,1===i.nesting&&r+1<e.length&&("inline"===(n=e[r+1]).type||n.hidden||-1===n.nesting&&n.tag===i.tag)&&(o=!1)),s+=o?">\n":">")},a.prototype.renderInline=function(e,r,t){for(var n,s="",o=this.rules,i=0,a=e.length;i<a;i++)void 0!==o[n=e[i].type]?s+=o[n](e,i,r,t,this):s+=this.renderToken(e,i,r);return s},a.prototype.renderInlineAsText=function(e,r,t){for(var n="",s=0,o=e.length;s<o;s++)"text"===e[s].type?n+=e[s].content:"image"===e[s].type&&(n+=this.renderInlineAsText(e[s].children,r,t));return n},a.prototype.render=function(e,r,t){var n,s,o,i="",a=this.rules;for(n=0,s=e.length;n<s;n++)"inline"===(o=e[n].type)?i+=this.renderInline(e[n].children,r,t):void 0!==a[o]?i+=a[e[n].type](e,n,r,t,this):i+=this.renderToken(e,n,r,t);return i},r.exports=a},{"./common/utils":4}],17:[function(e,r,t){"use strict";function n(){this.__rules__=[],this.__cache__=null}n.prototype.__find__=function(e){for(var r=0;r<this.__rules__.length;r++)if(this.__rules__[r].name===e)return r;return-1},n.prototype.__compile__=function(){var e=this,r=[""];e.__rules__.forEach((function(e){e.enabled&&e.alt.forEach((function(e){r.indexOf(e)<0&&r.push(e)}))})),e.__cache__={},r.forEach((function(r){e.__cache__[r]=[],e.__rules__.forEach((function(t){t.enabled&&(r&&t.alt.indexOf(r)<0||e.__cache__[r].push(t.fn))}))}))},n.prototype.at=function(e,r,t){var n=this.__find__(e),s=t||{};if(-1===n)throw new Error("Parser rule not found: "+e);this.__rules__[n].fn=r,this.__rules__[n].alt=s.alt||[],this.__cache__=null},n.prototype.before=function(e,r,t,n){var s=this.__find__(e),o=n||{};if(-1===s)throw new Error("Parser rule not found: "+e);this.__rules__.splice(s,0,{name:r,enabled:!0,fn:t,alt:o.alt||[]}),this.__cache__=null},n.prototype.after=function(e,r,t,n){var s=this.__find__(e),o=n||{};if(-1===s)throw new Error("Parser rule not found: "+e);this.__rules__.splice(s+1,0,{name:r,enabled:!0,fn:t,alt:o.alt||[]}),this.__cache__=null},n.prototype.push=function(e,r,t){var n=t||{};this.__rules__.push({name:e,enabled:!0,fn:r,alt:n.alt||[]}),this.__cache__=null},n.prototype.enable=function(e,r){Array.isArray(e)||(e=[e]);var t=[];return e.forEach((function(e){var n=this.__find__(e);if(n<0){if(r)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[n].enabled=!0,t.push(e)}),this),this.__cache__=null,t},n.prototype.enableOnly=function(e,r){Array.isArray(e)||(e=[e]),this.__rules__.forEach((function(e){e.enabled=!1})),this.enable(e,r)},n.prototype.disable=function(e,r){Array.isArray(e)||(e=[e]);var t=[];return e.forEach((function(e){var n=this.__find__(e);if(n<0){if(r)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[n].enabled=!1,t.push(e)}),this),this.__cache__=null,t},n.prototype.getRules=function(e){return null===this.__cache__&&this.__compile__(),this.__cache__[e]||[]},r.exports=n},{}],18:[function(e,r,t){"use strict";var n=e("../common/utils").isSpace;r.exports=function(e,r,t,s){var o,i,a,c,l,u,p,h,f,d,m,_,g,k,b,v,y,C,x,A,w=e.lineMax,D=e.bMarks[r]+e.tShift[r],E=e.eMarks[r];if(e.sCount[r]-e.blkIndent>=4)return!1;if(62!==e.src.charCodeAt(D++))return!1;if(s)return!0;for(c=f=e.sCount[r]+D-(e.bMarks[r]+e.tShift[r]),32===e.src.charCodeAt(D)?(D++,c++,f++,o=!1,v=!0):9===e.src.charCodeAt(D)?(v=!0,(e.bsCount[r]+f)%4==3?(D++,c++,f++,o=!1):o=!0):v=!1,d=[e.bMarks[r]],e.bMarks[r]=D;D<E&&(i=e.src.charCodeAt(D),n(i));)9===i?f+=4-(f+e.bsCount[r]+(o?1:0))%4:f++,D++;for(m=[e.bsCount[r]],e.bsCount[r]=e.sCount[r]+1+(v?1:0),u=D>=E,k=[e.sCount[r]],e.sCount[r]=f-c,b=[e.tShift[r]],e.tShift[r]=D-e.bMarks[r],C=e.md.block.ruler.getRules("blockquote"),g=e.parentType,e.parentType="blockquote",A=!1,h=r+1;h<t&&(e.sCount[h]<e.blkIndent&&(A=!0),!((D=e.bMarks[h]+e.tShift[h])>=(E=e.eMarks[h])));h++)if(62!==e.src.charCodeAt(D++)||A){if(u)break;for(y=!1,a=0,l=C.length;a<l;a++)if(C[a](e,h,t,!0)){y=!0;break}if(y){e.lineMax=h,0!==e.blkIndent&&(d.push(e.bMarks[h]),m.push(e.bsCount[h]),b.push(e.tShift[h]),k.push(e.sCount[h]),e.sCount[h]-=e.blkIndent);break}d.push(e.bMarks[h]),m.push(e.bsCount[h]),b.push(e.tShift[h]),k.push(e.sCount[h]),e.sCount[h]=-1}else{for(c=f=e.sCount[h]+D-(e.bMarks[h]+e.tShift[h]),32===e.src.charCodeAt(D)?(D++,c++,f++,o=!1,v=!0):9===e.src.charCodeAt(D)?(v=!0,(e.bsCount[h]+f)%4==3?(D++,c++,f++,o=!1):o=!0):v=!1,d.push(e.bMarks[h]),e.bMarks[h]=D;D<E&&(i=e.src.charCodeAt(D),n(i));)9===i?f+=4-(f+e.bsCount[h]+(o?1:0))%4:f++,D++;u=D>=E,m.push(e.bsCount[h]),e.bsCount[h]=e.sCount[h]+1+(v?1:0),k.push(e.sCount[h]),e.sCount[h]=f-c,b.push(e.tShift[h]),e.tShift[h]=D-e.bMarks[h]}for(_=e.blkIndent,e.blkIndent=0,(x=e.push("blockquote_open","blockquote",1)).markup=">",x.map=p=[r,0],e.md.block.tokenize(e,r,h),(x=e.push("blockquote_close","blockquote",-1)).markup=">",e.lineMax=w,e.parentType=g,p[1]=e.line,a=0;a<b.length;a++)e.bMarks[a+r]=d[a],e.tShift[a+r]=b[a],e.sCount[a+r]=k[a],e.bsCount[a+r]=m[a];return e.blkIndent=_,!0}},{"../common/utils":4}],19:[function(e,r,t){"use strict";r.exports=function(e,r,t){var n,s,o;if(e.sCount[r]-e.blkIndent<4)return!1;for(s=n=r+1;n<t;)if(e.isEmpty(n))n++;else{if(!(e.sCount[n]-e.blkIndent>=4))break;s=++n}return e.line=s,(o=e.push("code_block","code",0)).content=e.getLines(r,s,4+e.blkIndent,!0),o.map=[r,e.line],!0}},{}],20:[function(e,r,t){"use strict";r.exports=function(e,r,t,n){var s,o,i,a,c,l,u,p=!1,h=e.bMarks[r]+e.tShift[r],f=e.eMarks[r];if(e.sCount[r]-e.blkIndent>=4)return!1;if(h+3>f)return!1;if(126!==(s=e.src.charCodeAt(h))&&96!==s)return!1;if(c=h,(o=(h=e.skipChars(h,s))-c)<3)return!1;if(u=e.src.slice(c,h),i=e.src.slice(h,f),96===s&&i.indexOf(String.fromCharCode(s))>=0)return!1;if(n)return!0;for(a=r;!(++a>=t)&&!((h=c=e.bMarks[a]+e.tShift[a])<(f=e.eMarks[a])&&e.sCount[a]<e.blkIndent);)if(e.src.charCodeAt(h)===s&&!(e.sCount[a]-e.blkIndent>=4||(h=e.skipChars(h,s))-c<o||(h=e.skipSpaces(h))<f)){p=!0;break}return o=e.sCount[r],e.line=a+(p?1:0),(l=e.push("fence","code",0)).info=i,l.content=e.getLines(r+1,a,o,!0),l.markup=u,l.map=[r,e.line],!0}},{}],21:[function(e,r,t){"use strict";var n=e("../common/utils").isSpace;r.exports=function(e,r,t,s){var o,i,a,c,l=e.bMarks[r]+e.tShift[r],u=e.eMarks[r];if(e.sCount[r]-e.blkIndent>=4)return!1;if(35!==(o=e.src.charCodeAt(l))||l>=u)return!1;for(i=1,o=e.src.charCodeAt(++l);35===o&&l<u&&i<=6;)i++,o=e.src.charCodeAt(++l);return!(i>6||l<u&&!n(o))&&(s||(u=e.skipSpacesBack(u,l),(a=e.skipCharsBack(u,35,l))>l&&n(e.src.charCodeAt(a-1))&&(u=a),e.line=r+1,(c=e.push("heading_open","h"+String(i),1)).markup="########".slice(0,i),c.map=[r,e.line],(c=e.push("inline","",0)).content=e.src.slice(l,u).trim(),c.map=[r,e.line],c.children=[],(c=e.push("heading_close","h"+String(i),-1)).markup="########".slice(0,i)),!0)}},{"../common/utils":4}],22:[function(e,r,t){"use strict";var n=e("../common/utils").isSpace;r.exports=function(e,r,t,s){var o,i,a,c,l=e.bMarks[r]+e.tShift[r],u=e.eMarks[r];if(e.sCount[r]-e.blkIndent>=4)return!1;if(42!==(o=e.src.charCodeAt(l++))&&45!==o&&95!==o)return!1;for(i=1;l<u;){if((a=e.src.charCodeAt(l++))!==o&&!n(a))return!1;a===o&&i++}return!(i<3)&&(s||(e.line=r+1,(c=e.push("hr","hr",0)).map=[r,e.line],c.markup=Array(i+1).join(String.fromCharCode(o))),!0)}},{"../common/utils":4}],23:[function(e,r,t){"use strict";var n=e("../common/html_blocks"),s=e("../common/html_re").HTML_OPEN_CLOSE_TAG_RE,o=[[/^<(script|pre|style)(?=(\s|>|$))/i,/<\/(script|pre|style)>/i,!0],[/^<!--/,/-->/,!0],[/^<\?/,/\?>/,!0],[/^<![A-Z]/,/>/,!0],[/^<!\[CDATA\[/,/\]\]>/,!0],[new RegExp("^</?("+n.join("|")+")(?=(\\s|/?>|$))","i"),/^$/,!0],[new RegExp(s.source+"\\s*$"),/^$/,!1]];r.exports=function(e,r,t,n){var s,i,a,c,l=e.bMarks[r]+e.tShift[r],u=e.eMarks[r];if(e.sCount[r]-e.blkIndent>=4)return!1;if(!e.md.options.html)return!1;if(60!==e.src.charCodeAt(l))return!1;for(c=e.src.slice(l,u),s=0;s<o.length&&!o[s][0].test(c);s++);if(s===o.length)return!1;if(n)return o[s][2];if(i=r+1,!o[s][1].test(c))for(;i<t&&!(e.sCount[i]<e.blkIndent);i++)if(l=e.bMarks[i]+e.tShift[i],u=e.eMarks[i],c=e.src.slice(l,u),o[s][1].test(c)){0!==c.length&&i++;break}return e.line=i,(a=e.push("html_block","",0)).map=[r,i],a.content=e.getLines(r,i,e.blkIndent,!0),!0}},{"../common/html_blocks":2,"../common/html_re":3}],24:[function(e,r,t){"use strict";r.exports=function(e,r,t){var n,s,o,i,a,c,l,u,p,h,f=r+1,d=e.md.block.ruler.getRules("paragraph");if(e.sCount[r]-e.blkIndent>=4)return!1;for(h=e.parentType,e.parentType="paragraph";f<t&&!e.isEmpty(f);f++)if(!(e.sCount[f]-e.blkIndent>3)){if(e.sCount[f]>=e.blkIndent&&(c=e.bMarks[f]+e.tShift[f])<(l=e.eMarks[f])&&(45===(p=e.src.charCodeAt(c))||61===p)&&(c=e.skipChars(c,p),(c=e.skipSpaces(c))>=l)){u=61===p?1:2;break}if(!(e.sCount[f]<0)){for(s=!1,o=0,i=d.length;o<i;o++)if(d[o](e,f,t,!0)){s=!0;break}if(s)break}}return!!u&&(n=e.getLines(r,f,e.blkIndent,!1).trim(),e.line=f+1,(a=e.push("heading_open","h"+String(u),1)).markup=String.fromCharCode(p),a.map=[r,e.line],(a=e.push("inline","",0)).content=n,a.map=[r,e.line-1],a.children=[],(a=e.push("heading_close","h"+String(u),-1)).markup=String.fromCharCode(p),e.parentType=h,!0)}},{}],25:[function(e,r,t){"use strict";var n=e("../common/utils").isSpace;function s(e,r){var t,s,o,i;return s=e.bMarks[r]+e.tShift[r],o=e.eMarks[r],42!==(t=e.src.charCodeAt(s++))&&45!==t&&43!==t||s<o&&(i=e.src.charCodeAt(s),!n(i))?-1:s}function o(e,r){var t,s=e.bMarks[r]+e.tShift[r],o=s,i=e.eMarks[r];if(o+1>=i)return-1;if((t=e.src.charCodeAt(o++))<48||t>57)return-1;for(;;){if(o>=i)return-1;if(!((t=e.src.charCodeAt(o++))>=48&&t<=57)){if(41===t||46===t)break;return-1}if(o-s>=10)return-1}return o<i&&(t=e.src.charCodeAt(o),!n(t))?-1:o}r.exports=function(e,r,t,n){var i,a,c,l,u,p,h,f,d,m,_,g,k,b,v,y,C,x,A,w,D,E,q,F,S,L,z,T,I=!1,R=!0;if(e.sCount[r]-e.blkIndent>=4)return!1;if(e.listIndent>=0&&e.sCount[r]-e.listIndent>=4&&e.sCount[r]<e.blkIndent)return!1;if(n&&"paragraph"===e.parentType&&e.tShift[r]>=e.blkIndent&&(I=!0),(q=o(e,r))>=0){if(h=!0,S=e.bMarks[r]+e.tShift[r],k=Number(e.src.substr(S,q-S-1)),I&&1!==k)return!1}else{if(!((q=s(e,r))>=0))return!1;h=!1}if(I&&e.skipSpaces(q)>=e.eMarks[r])return!1;if(g=e.src.charCodeAt(q-1),n)return!0;for(_=e.tokens.length,h?(T=e.push("ordered_list_open","ol",1),1!==k&&(T.attrs=[["start",k]])):T=e.push("bullet_list_open","ul",1),T.map=m=[r,0],T.markup=String.fromCharCode(g),v=r,F=!1,z=e.md.block.ruler.getRules("list"),x=e.parentType,e.parentType="list";v<t;){for(E=q,b=e.eMarks[v],p=y=e.sCount[v]+q-(e.bMarks[r]+e.tShift[r]);E<b;){if(9===(i=e.src.charCodeAt(E)))y+=4-(y+e.bsCount[v])%4;else{if(32!==i)break;y++}E++}if((u=(a=E)>=b?1:y-p)>4&&(u=1),l=p+u,(T=e.push("list_item_open","li",1)).markup=String.fromCharCode(g),T.map=f=[r,0],D=e.tight,w=e.tShift[r],A=e.sCount[r],C=e.listIndent,e.listIndent=e.blkIndent,e.blkIndent=l,e.tight=!0,e.tShift[r]=a-e.bMarks[r],e.sCount[r]=y,a>=b&&e.isEmpty(r+1)?e.line=Math.min(e.line+2,t):e.md.block.tokenize(e,r,t,!0),e.tight&&!F||(R=!1),F=e.line-r>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=C,e.tShift[r]=w,e.sCount[r]=A,e.tight=D,(T=e.push("list_item_close","li",-1)).markup=String.fromCharCode(g),v=r=e.line,f[1]=v,a=e.bMarks[r],v>=t)break;if(e.sCount[v]<e.blkIndent)break;if(e.sCount[r]-e.blkIndent>=4)break;for(L=!1,c=0,d=z.length;c<d;c++)if(z[c](e,v,t,!0)){L=!0;break}if(L)break;if(h){if((q=o(e,v))<0)break}else if((q=s(e,v))<0)break;if(g!==e.src.charCodeAt(q-1))break}return(T=h?e.push("ordered_list_close","ol",-1):e.push("bullet_list_close","ul",-1)).markup=String.fromCharCode(g),m[1]=v,e.line=v,e.parentType=x,R&&function(e,r){var t,n,s=e.level+2;for(t=r+2,n=e.tokens.length-2;t<n;t++)e.tokens[t].level===s&&"paragraph_open"===e.tokens[t].type&&(e.tokens[t+2].hidden=!0,e.tokens[t].hidden=!0,t+=2)}(e,_),!0}},{"../common/utils":4}],26:[function(e,r,t){"use strict";r.exports=function(e,r){var t,n,s,o,i,a,c=r+1,l=e.md.block.ruler.getRules("paragraph"),u=e.lineMax;for(a=e.parentType,e.parentType="paragraph";c<u&&!e.isEmpty(c);c++)if(!(e.sCount[c]-e.blkIndent>3||e.sCount[c]<0)){for(n=!1,s=0,o=l.length;s<o;s++)if(l[s](e,c,u,!0)){n=!0;break}if(n)break}return t=e.getLines(r,c,e.blkIndent,!1).trim(),e.line=c,(i=e.push("paragraph_open","p",1)).map=[r,e.line],(i=e.push("inline","",0)).content=t,i.map=[r,e.line],i.children=[],i=e.push("paragraph_close","p",-1),e.parentType=a,!0}},{}],27:[function(e,r,t){"use strict";var n=e("../common/utils").normalizeReference,s=e("../common/utils").isSpace;r.exports=function(e,r,t,o){var i,a,c,l,u,p,h,f,d,m,_,g,k,b,v,y,C=0,x=e.bMarks[r]+e.tShift[r],A=e.eMarks[r],w=r+1;if(e.sCount[r]-e.blkIndent>=4)return!1;if(91!==e.src.charCodeAt(x))return!1;for(;++x<A;)if(93===e.src.charCodeAt(x)&&92!==e.src.charCodeAt(x-1)){if(x+1===A)return!1;if(58!==e.src.charCodeAt(x+1))return!1;break}for(l=e.lineMax,v=e.md.block.ruler.getRules("reference"),m=e.parentType,e.parentType="reference";w<l&&!e.isEmpty(w);w++)if(!(e.sCount[w]-e.blkIndent>3||e.sCount[w]<0)){for(b=!1,p=0,h=v.length;p<h;p++)if(v[p](e,w,l,!0)){b=!0;break}if(b)break}for(A=(k=e.getLines(r,w,e.blkIndent,!1).trim()).length,x=1;x<A;x++){if(91===(i=k.charCodeAt(x)))return!1;if(93===i){d=x;break}(10===i||92===i&&++x<A&&10===k.charCodeAt(x))&&C++}if(d<0||58!==k.charCodeAt(d+1))return!1;for(x=d+2;x<A;x++)if(10===(i=k.charCodeAt(x)))C++;else if(!s(i))break;if(!(_=e.md.helpers.parseLinkDestination(k,x,A)).ok)return!1;if(u=e.md.normalizeLink(_.str),!e.md.validateLink(u))return!1;for(a=x=_.pos,c=C+=_.lines,g=x;x<A;x++)if(10===(i=k.charCodeAt(x)))C++;else if(!s(i))break;for(_=e.md.helpers.parseLinkTitle(k,x,A),x<A&&g!==x&&_.ok?(y=_.str,x=_.pos,C+=_.lines):(y="",x=a,C=c);x<A&&(i=k.charCodeAt(x),s(i));)x++;if(x<A&&10!==k.charCodeAt(x)&&y)for(y="",x=a,C=c;x<A&&(i=k.charCodeAt(x),s(i));)x++;return!(x<A&&10!==k.charCodeAt(x))&&(!!(f=n(k.slice(1,d)))&&(o||(void 0===e.env.references&&(e.env.references={}),void 0===e.env.references[f]&&(e.env.references[f]={title:y,href:u}),e.parentType=m,e.line=r+C+1),!0))}},{"../common/utils":4}],28:[function(e,r,t){"use strict";var n=e("../token"),s=e("../common/utils").isSpace;function o(e,r,t,n){var o,i,a,c,l,u,p,h;for(this.src=e,this.md=r,this.env=t,this.tokens=n,this.bMarks=[],this.eMarks=[],this.tShift=[],this.sCount=[],this.bsCount=[],this.blkIndent=0,this.line=0,this.lineMax=0,this.tight=!1,this.ddIndent=-1,this.listIndent=-1,this.parentType="root",this.level=0,this.result="",h=!1,a=c=u=p=0,l=(i=this.src).length;c<l;c++){if(o=i.charCodeAt(c),!h){if(s(o)){u++,9===o?p+=4-p%4:p++;continue}h=!0}10!==o&&c!==l-1||(10!==o&&c++,this.bMarks.push(a),this.eMarks.push(c),this.tShift.push(u),this.sCount.push(p),this.bsCount.push(0),h=!1,u=0,p=0,a=c+1)}this.bMarks.push(i.length),this.eMarks.push(i.length),this.tShift.push(0),this.sCount.push(0),this.bsCount.push(0),this.lineMax=this.bMarks.length-1}o.prototype.push=function(e,r,t){var s=new n(e,r,t);return s.block=!0,t<0&&this.level--,s.level=this.level,t>0&&this.level++,this.tokens.push(s),s},o.prototype.isEmpty=function(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]},o.prototype.skipEmptyLines=function(e){for(var r=this.lineMax;e<r&&!(this.bMarks[e]+this.tShift[e]<this.eMarks[e]);e++);return e},o.prototype.skipSpaces=function(e){for(var r,t=this.src.length;e<t&&(r=this.src.charCodeAt(e),s(r));e++);return e},o.prototype.skipSpacesBack=function(e,r){if(e<=r)return e;for(;e>r;)if(!s(this.src.charCodeAt(--e)))return e+1;return e},o.prototype.skipChars=function(e,r){for(var t=this.src.length;e<t&&this.src.charCodeAt(e)===r;e++);return e},o.prototype.skipCharsBack=function(e,r,t){if(e<=t)return e;for(;e>t;)if(r!==this.src.charCodeAt(--e))return e+1;return e},o.prototype.getLines=function(e,r,t,n){var o,i,a,c,l,u,p,h=e;if(e>=r)return"";for(u=new Array(r-e),o=0;h<r;h++,o++){for(i=0,p=c=this.bMarks[h],l=h+1<r||n?this.eMarks[h]+1:this.eMarks[h];c<l&&i<t;){if(a=this.src.charCodeAt(c),s(a))9===a?i+=4-(i+this.bsCount[h])%4:i++;else{if(!(c-p<this.tShift[h]))break;i++}c++}u[o]=i>t?new Array(i-t+1).join(" ")+this.src.slice(c,l):this.src.slice(c,l)}return u.join("")},o.prototype.Token=n,r.exports=o},{"../common/utils":4,"../token":51}],29:[function(e,r,t){"use strict";var n=e("../common/utils").isSpace;function s(e,r){var t=e.bMarks[r]+e.blkIndent,n=e.eMarks[r];return e.src.substr(t,n-t)}function o(e){var r,t=[],n=0,s=e.length,o=0,i=0,a=!1,c=0;for(r=e.charCodeAt(n);n<s;)96===r?a?(a=!1,c=n):o%2==0&&(a=!0,c=n):124!==r||o%2!=0||a||(t.push(e.substring(i,n)),i=n+1),92===r?o++:o=0,++n===s&&a&&(a=!1,n=c+1),r=e.charCodeAt(n);return t.push(e.substring(i)),t}r.exports=function(e,r,t,i){var a,c,l,u,p,h,f,d,m,_,g,k;if(r+2>t)return!1;if(p=r+1,e.sCount[p]<e.blkIndent)return!1;if(e.sCount[p]-e.blkIndent>=4)return!1;if((l=e.bMarks[p]+e.tShift[p])>=e.eMarks[p])return!1;if(124!==(a=e.src.charCodeAt(l++))&&45!==a&&58!==a)return!1;for(;l<e.eMarks[p];){if(124!==(a=e.src.charCodeAt(l))&&45!==a&&58!==a&&!n(a))return!1;l++}for(h=(c=s(e,r+1)).split("|"),m=[],u=0;u<h.length;u++){if(!(_=h[u].trim())){if(0===u||u===h.length-1)continue;return!1}if(!/^:?-+:?$/.test(_))return!1;58===_.charCodeAt(_.length-1)?m.push(58===_.charCodeAt(0)?"center":"right"):58===_.charCodeAt(0)?m.push("left"):m.push("")}if(-1===(c=s(e,r).trim()).indexOf("|"))return!1;if(e.sCount[r]-e.blkIndent>=4)return!1;if((f=(h=o(c.replace(/^\||\|$/g,""))).length)>m.length)return!1;if(i)return!0;for((d=e.push("table_open","table",1)).map=g=[r,0],(d=e.push("thead_open","thead",1)).map=[r,r+1],(d=e.push("tr_open","tr",1)).map=[r,r+1],u=0;u<h.length;u++)(d=e.push("th_open","th",1)).map=[r,r+1],m[u]&&(d.attrs=[["style","text-align:"+m[u]]]),(d=e.push("inline","",0)).content=h[u].trim(),d.map=[r,r+1],d.children=[],d=e.push("th_close","th",-1);for(d=e.push("tr_close","tr",-1),d=e.push("thead_close","thead",-1),(d=e.push("tbody_open","tbody",1)).map=k=[r+2,0],p=r+2;p<t&&!(e.sCount[p]<e.blkIndent)&&-1!==(c=s(e,p).trim()).indexOf("|")&&!(e.sCount[p]-e.blkIndent>=4);p++){for(h=o(c.replace(/^\||\|$/g,"")),d=e.push("tr_open","tr",1),u=0;u<f;u++)d=e.push("td_open","td",1),m[u]&&(d.attrs=[["style","text-align:"+m[u]]]),(d=e.push("inline","",0)).content=h[u]?h[u].trim():"",d.children=[],d=e.push("td_close","td",-1);d=e.push("tr_close","tr",-1)}return d=e.push("tbody_close","tbody",-1),d=e.push("table_close","table",-1),g[1]=k[1]=p,e.line=p,!0}},{"../common/utils":4}],30:[function(e,r,t){"use strict";r.exports=function(e){var r;e.inlineMode?((r=new e.Token("inline","",0)).content=e.src,r.map=[0,1],r.children=[],e.tokens.push(r)):e.md.block.parse(e.src,e.md,e.env,e.tokens)}},{}],31:[function(e,r,t){"use strict";r.exports=function(e){var r,t,n,s=e.tokens;for(t=0,n=s.length;t<n;t++)"inline"===(r=s[t]).type&&e.md.inline.parse(r.content,e.md,e.env,r.children)}},{}],32:[function(e,r,t){"use strict";var n=e("../common/utils").arrayReplaceAt;function s(e){return/^<\/a\s*>/i.test(e)}r.exports=function(e){var r,t,o,i,a,c,l,u,p,h,f,d,m,_,g,k,b,v,y=e.tokens;if(e.md.options.linkify)for(t=0,o=y.length;t<o;t++)if("inline"===y[t].type&&e.md.linkify.pretest(y[t].content))for(m=0,r=(i=y[t].children).length-1;r>=0;r--)if("link_close"!==(c=i[r]).type){if("html_inline"===c.type&&(v=c.content,/^<a[>\s]/i.test(v)&&m>0&&m--,s(c.content)&&m++),!(m>0)&&"text"===c.type&&e.md.linkify.test(c.content)){for(p=c.content,b=e.md.linkify.match(p),l=[],d=c.level,f=0,u=0;u<b.length;u++)_=b[u].url,g=e.md.normalizeLink(_),e.md.validateLink(g)&&(k=b[u].text,k=b[u].schema?"mailto:"!==b[u].schema||/^mailto:/i.test(k)?e.md.normalizeLinkText(k):e.md.normalizeLinkText("mailto:"+k).replace(/^mailto:/,""):e.md.normalizeLinkText("http://"+k).replace(/^http:\/\//,""),(h=b[u].index)>f&&((a=new e.Token("text","",0)).content=p.slice(f,h),a.level=d,l.push(a)),(a=new e.Token("link_open","a",1)).attrs=[["href",g]],a.level=d++,a.markup="linkify",a.info="auto",l.push(a),(a=new e.Token("text","",0)).content=k,a.level=d,l.push(a),(a=new e.Token("link_close","a",-1)).level=--d,a.markup="linkify",a.info="auto",l.push(a),f=b[u].lastIndex);f<p.length&&((a=new e.Token("text","",0)).content=p.slice(f),a.level=d,l.push(a)),y[t].children=i=n(i,r,l)}}else for(r--;i[r].level!==c.level&&"link_open"!==i[r].type;)r--}},{"../common/utils":4}],33:[function(e,r,t){"use strict";var n=/\r\n?|\n/g,s=/\0/g;r.exports=function(e){var r;r=(r=e.src.replace(n,"\n")).replace(s,"\ufffd"),e.src=r}},{}],34:[function(e,r,t){"use strict";var n=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,s=/\((c|tm|r|p)\)/i,o=/\((c|tm|r|p)\)/gi,i={c:"\xa9",r:"\xae",p:"\xa7",tm:"\u2122"};function a(e,r){return i[r.toLowerCase()]}function c(e){var r,t,n=0;for(r=e.length-1;r>=0;r--)"text"!==(t=e[r]).type||n||(t.content=t.content.replace(o,a)),"link_open"===t.type&&"auto"===t.info&&n--,"link_close"===t.type&&"auto"===t.info&&n++}function l(e){var r,t,s=0;for(r=e.length-1;r>=0;r--)"text"!==(t=e[r]).type||s||n.test(t.content)&&(t.content=t.content.replace(/\+-/g,"\xb1").replace(/\.{2,}/g,"\u2026").replace(/([?!])\u2026/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/gm,"$1\u2014").replace(/(^|\s)--(?=\s|$)/gm,"$1\u2013").replace(/(^|[^-\s])--(?=[^-\s]|$)/gm,"$1\u2013")),"link_open"===t.type&&"auto"===t.info&&s--,"link_close"===t.type&&"auto"===t.info&&s++}r.exports=function(e){var r;if(e.md.options.typographer)for(r=e.tokens.length-1;r>=0;r--)"inline"===e.tokens[r].type&&(s.test(e.tokens[r].content)&&c(e.tokens[r].children),n.test(e.tokens[r].content)&&l(e.tokens[r].children))}},{}],35:[function(e,r,t){"use strict";var n=e("../common/utils").isWhiteSpace,s=e("../common/utils").isPunctChar,o=e("../common/utils").isMdAsciiPunct,i=/['"]/,a=/['"]/g;function c(e,r,t){return e.substr(0,r)+t+e.substr(r+1)}function l(e,r){var t,i,l,u,p,h,f,d,m,_,g,k,b,v,y,C,x,A,w,D,E;for(w=[],t=0;t<e.length;t++){for(i=e[t],f=e[t].level,x=w.length-1;x>=0&&!(w[x].level<=f);x--);if(w.length=x+1,"text"===i.type){p=0,h=(l=i.content).length;e:for(;p<h&&(a.lastIndex=p,u=a.exec(l));){if(y=C=!0,p=u.index+1,A="'"===u[0],m=32,u.index-1>=0)m=l.charCodeAt(u.index-1);else for(x=t-1;x>=0&&("softbreak"!==e[x].type&&"hardbreak"!==e[x].type);x--)if("text"===e[x].type){m=e[x].content.charCodeAt(e[x].content.length-1);break}if(_=32,p<h)_=l.charCodeAt(p);else for(x=t+1;x<e.length&&("softbreak"!==e[x].type&&"hardbreak"!==e[x].type);x++)if("text"===e[x].type){_=e[x].content.charCodeAt(0);break}if(g=o(m)||s(String.fromCharCode(m)),k=o(_)||s(String.fromCharCode(_)),b=n(m),(v=n(_))?y=!1:k&&(b||g||(y=!1)),b?C=!1:g&&(v||k||(C=!1)),34===_&&'"'===u[0]&&m>=48&&m<=57&&(C=y=!1),y&&C&&(y=g,C=k),y||C){if(C)for(x=w.length-1;x>=0&&(d=w[x],!(w[x].level<f));x--)if(d.single===A&&w[x].level===f){d=w[x],A?(D=r.md.options.quotes[2],E=r.md.options.quotes[3]):(D=r.md.options.quotes[0],E=r.md.options.quotes[1]),i.content=c(i.content,u.index,E),e[d.token].content=c(e[d.token].content,d.pos,D),p+=E.length-1,d.token===t&&(p+=D.length-1),h=(l=i.content).length,w.length=x;continue e}y?w.push({token:t,pos:u.index,single:A,level:f}):C&&A&&(i.content=c(i.content,u.index,"\u2019"))}else A&&(i.content=c(i.content,u.index,"\u2019"))}}}}r.exports=function(e){var r;if(e.md.options.typographer)for(r=e.tokens.length-1;r>=0;r--)"inline"===e.tokens[r].type&&i.test(e.tokens[r].content)&&l(e.tokens[r].children,e)}},{"../common/utils":4}],36:[function(e,r,t){"use strict";var n=e("../token");function s(e,r,t){this.src=e,this.env=t,this.tokens=[],this.inlineMode=!1,this.md=r}s.prototype.Token=n,r.exports=s},{"../token":51}],37:[function(e,r,t){"use strict";var n=/^<([a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)>/,s=/^<([a-zA-Z][a-zA-Z0-9+.\-]{1,31}):([^<>\x00-\x20]*)>/;r.exports=function(e,r){var t,o,i,a,c,l,u=e.pos;return 60===e.src.charCodeAt(u)&&(!((t=e.src.slice(u)).indexOf(">")<0)&&(s.test(t)?(a=(o=t.match(s))[0].slice(1,-1),c=e.md.normalizeLink(a),!!e.md.validateLink(c)&&(r||((l=e.push("link_open","a",1)).attrs=[["href",c]],l.markup="autolink",l.info="auto",(l=e.push("text","",0)).content=e.md.normalizeLinkText(a),(l=e.push("link_close","a",-1)).markup="autolink",l.info="auto"),e.pos+=o[0].length,!0)):!!n.test(t)&&(a=(i=t.match(n))[0].slice(1,-1),c=e.md.normalizeLink("mailto:"+a),!!e.md.validateLink(c)&&(r||((l=e.push("link_open","a",1)).attrs=[["href",c]],l.markup="autolink",l.info="auto",(l=e.push("text","",0)).content=e.md.normalizeLinkText(a),(l=e.push("link_close","a",-1)).markup="autolink",l.info="auto"),e.pos+=i[0].length,!0))))}},{}],38:[function(e,r,t){"use strict";r.exports=function(e,r){var t,n,s,o,i,a,c=e.pos;if(96!==e.src.charCodeAt(c))return!1;for(t=c,c++,n=e.posMax;c<n&&96===e.src.charCodeAt(c);)c++;for(s=e.src.slice(t,c),o=i=c;-1!==(o=e.src.indexOf("`",i));){for(i=o+1;i<n&&96===e.src.charCodeAt(i);)i++;if(i-o===s.length)return r||((a=e.push("code_inline","code",0)).markup=s,a.content=e.src.slice(c,o).replace(/\n/g," ").replace(/^ (.+) $/,"$1")),e.pos=i,!0}return r||(e.pending+=s),e.pos+=s.length,!0}},{}],39:[function(e,r,t){"use strict";function n(e,r){var t,n,s,o,i,a,c,l,u={},p=r.length;for(t=0;t<p;t++)if((s=r[t]).length=s.length||0,s.close){for(u.hasOwnProperty(s.marker)||(u[s.marker]=[-1,-1,-1]),i=u[s.marker][s.length%3],a=-1,n=t-s.jump-1;n>i;n-=o.jump+1)if((o=r[n]).marker===s.marker&&(-1===a&&(a=n),o.open&&o.end<0&&o.level===s.level&&(c=!1,(o.close||s.open)&&(o.length+s.length)%3==0&&(o.length%3==0&&s.length%3==0||(c=!0)),!c))){l=n>0&&!r[n-1].open?r[n-1].jump+1:0,s.jump=t-n+l,s.open=!1,o.end=t,o.jump=l,o.close=!1,a=-1;break}-1!==a&&(u[s.marker][(s.length||0)%3]=a)}}r.exports=function(e){var r,t=e.tokens_meta,s=e.tokens_meta.length;for(n(0,e.delimiters),r=0;r<s;r++)t[r]&&t[r].delimiters&&n(0,t[r].delimiters)}},{}],40:[function(e,r,t){"use strict";function n(e,r){var t,n,s,o,i,a;for(t=r.length-1;t>=0;t--)95!==(n=r[t]).marker&&42!==n.marker||-1!==n.end&&(s=r[n.end],a=t>0&&r[t-1].end===n.end+1&&r[t-1].token===n.token-1&&r[n.end+1].token===s.token+1&&r[t-1].marker===n.marker,i=String.fromCharCode(n.marker),(o=e.tokens[n.token]).type=a?"strong_open":"em_open",o.tag=a?"strong":"em",o.nesting=1,o.markup=a?i+i:i,o.content="",(o=e.tokens[s.token]).type=a?"strong_close":"em_close",o.tag=a?"strong":"em",o.nesting=-1,o.markup=a?i+i:i,o.content="",a&&(e.tokens[r[t-1].token].content="",e.tokens[r[n.end+1].token].content="",t--))}r.exports.tokenize=function(e,r){var t,n,s=e.pos,o=e.src.charCodeAt(s);if(r)return!1;if(95!==o&&42!==o)return!1;for(n=e.scanDelims(e.pos,42===o),t=0;t<n.length;t++)e.push("text","",0).content=String.fromCharCode(o),e.delimiters.push({marker:o,length:n.length,jump:t,token:e.tokens.length-1,end:-1,open:n.can_open,close:n.can_close});return e.pos+=n.length,!0},r.exports.postProcess=function(e){var r,t=e.tokens_meta,s=e.tokens_meta.length;for(n(e,e.delimiters),r=0;r<s;r++)t[r]&&t[r].delimiters&&n(e,t[r].delimiters)}},{}],41:[function(e,r,t){"use strict";var n=e("../common/entities"),s=e("../common/utils").has,o=e("../common/utils").isValidEntityCode,i=e("../common/utils").fromCodePoint,a=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,c=/^&([a-z][a-z0-9]{1,31});/i;r.exports=function(e,r){var t,l,u=e.pos,p=e.posMax;if(38!==e.src.charCodeAt(u))return!1;if(u+1<p)if(35===e.src.charCodeAt(u+1)){if(l=e.src.slice(u).match(a))return r||(t="x"===l[1][0].toLowerCase()?parseInt(l[1].slice(1),16):parseInt(l[1],10),e.pending+=o(t)?i(t):i(65533)),e.pos+=l[0].length,!0}else if((l=e.src.slice(u).match(c))&&s(n,l[1]))return r||(e.pending+=n[l[1]]),e.pos+=l[0].length,!0;return r||(e.pending+="&"),e.pos++,!0}},{"../common/entities":1,"../common/utils":4}],42:[function(e,r,t){"use strict";for(var n=e("../common/utils").isSpace,s=[],o=0;o<256;o++)s.push(0);"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach((function(e){s[e.charCodeAt(0)]=1})),r.exports=function(e,r){var t,o=e.pos,i=e.posMax;if(92!==e.src.charCodeAt(o))return!1;if(++o<i){if((t=e.src.charCodeAt(o))<256&&0!==s[t])return r||(e.pending+=e.src[o]),e.pos+=2,!0;if(10===t){for(r||e.push("hardbreak","br",0),o++;o<i&&(t=e.src.charCodeAt(o),n(t));)o++;return e.pos=o,!0}}return r||(e.pending+="\\"),e.pos++,!0}},{"../common/utils":4}],43:[function(e,r,t){"use strict";var n=e("../common/html_re").HTML_TAG_RE;r.exports=function(e,r){var t,s,o,i=e.pos;return!!e.md.options.html&&(o=e.posMax,!(60!==e.src.charCodeAt(i)||i+2>=o)&&(!(33!==(t=e.src.charCodeAt(i+1))&&63!==t&&47!==t&&!function(e){var r=32|e;return r>=97&&r<=122}(t))&&(!!(s=e.src.slice(i).match(n))&&(r||(e.push("html_inline","",0).content=e.src.slice(i,i+s[0].length)),e.pos+=s[0].length,!0))))}},{"../common/html_re":3}],44:[function(e,r,t){"use strict";var n=e("../common/utils").normalizeReference,s=e("../common/utils").isSpace;r.exports=function(e,r){var t,o,i,a,c,l,u,p,h,f,d,m,_,g="",k=e.pos,b=e.posMax;if(33!==e.src.charCodeAt(e.pos))return!1;if(91!==e.src.charCodeAt(e.pos+1))return!1;if(l=e.pos+2,(c=e.md.helpers.parseLinkLabel(e,e.pos+1,!1))<0)return!1;if((u=c+1)<b&&40===e.src.charCodeAt(u)){for(u++;u<b&&(o=e.src.charCodeAt(u),s(o)||10===o);u++);if(u>=b)return!1;for(_=u,(h=e.md.helpers.parseLinkDestination(e.src,u,e.posMax)).ok&&(g=e.md.normalizeLink(h.str),e.md.validateLink(g)?u=h.pos:g=""),_=u;u<b&&(o=e.src.charCodeAt(u),s(o)||10===o);u++);if(h=e.md.helpers.parseLinkTitle(e.src,u,e.posMax),u<b&&_!==u&&h.ok)for(f=h.str,u=h.pos;u<b&&(o=e.src.charCodeAt(u),s(o)||10===o);u++);else f="";if(u>=b||41!==e.src.charCodeAt(u))return e.pos=k,!1;u++}else{if(void 0===e.env.references)return!1;if(u<b&&91===e.src.charCodeAt(u)?(_=u+1,(u=e.md.helpers.parseLinkLabel(e,u))>=0?a=e.src.slice(_,u++):u=c+1):u=c+1,a||(a=e.src.slice(l,c)),!(p=e.env.references[n(a)]))return e.pos=k,!1;g=p.href,f=p.title}return r||(i=e.src.slice(l,c),e.md.inline.parse(i,e.md,e.env,m=[]),(d=e.push("image","img",0)).attrs=t=[["src",g],["alt",""]],d.children=m,d.content=i,f&&t.push(["title",f])),e.pos=u,e.posMax=b,!0}},{"../common/utils":4}],45:[function(e,r,t){"use strict";var n=e("../common/utils").normalizeReference,s=e("../common/utils").isSpace;r.exports=function(e,r){var t,o,i,a,c,l,u,p,h,f="",d=e.pos,m=e.posMax,_=e.pos,g=!0;if(91!==e.src.charCodeAt(e.pos))return!1;if(c=e.pos+1,(a=e.md.helpers.parseLinkLabel(e,e.pos,!0))<0)return!1;if((l=a+1)<m&&40===e.src.charCodeAt(l)){for(g=!1,l++;l<m&&(o=e.src.charCodeAt(l),s(o)||10===o);l++);if(l>=m)return!1;for(_=l,(u=e.md.helpers.parseLinkDestination(e.src,l,e.posMax)).ok&&(f=e.md.normalizeLink(u.str),e.md.validateLink(f)?l=u.pos:f=""),_=l;l<m&&(o=e.src.charCodeAt(l),s(o)||10===o);l++);if(u=e.md.helpers.parseLinkTitle(e.src,l,e.posMax),l<m&&_!==l&&u.ok)for(h=u.str,l=u.pos;l<m&&(o=e.src.charCodeAt(l),s(o)||10===o);l++);else h="";(l>=m||41!==e.src.charCodeAt(l))&&(g=!0),l++}if(g){if(void 0===e.env.references)return!1;if(l<m&&91===e.src.charCodeAt(l)?(_=l+1,(l=e.md.helpers.parseLinkLabel(e,l))>=0?i=e.src.slice(_,l++):l=a+1):l=a+1,i||(i=e.src.slice(c,a)),!(p=e.env.references[n(i)]))return e.pos=d,!1;f=p.href,h=p.title}return r||(e.pos=c,e.posMax=a,e.push("link_open","a",1).attrs=t=[["href",f]],h&&t.push(["title",h]),e.md.inline.tokenize(e),e.push("link_close","a",-1)),e.pos=l,e.posMax=m,!0}},{"../common/utils":4}],46:[function(e,r,t){"use strict";var n=e("../common/utils").isSpace;r.exports=function(e,r){var t,s,o=e.pos;if(10!==e.src.charCodeAt(o))return!1;for(t=e.pending.length-1,s=e.posMax,r||(t>=0&&32===e.pending.charCodeAt(t)?t>=1&&32===e.pending.charCodeAt(t-1)?(e.pending=e.pending.replace(/ +$/,""),e.push("hardbreak","br",0)):(e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0)):e.push("softbreak","br",0)),o++;o<s&&n(e.src.charCodeAt(o));)o++;return e.pos=o,!0}},{"../common/utils":4}],47:[function(e,r,t){"use strict";var n=e("../token"),s=e("../common/utils").isWhiteSpace,o=e("../common/utils").isPunctChar,i=e("../common/utils").isMdAsciiPunct;function a(e,r,t,n){this.src=e,this.env=t,this.md=r,this.tokens=n,this.tokens_meta=Array(n.length),this.pos=0,this.posMax=this.src.length,this.level=0,this.pending="",this.pendingLevel=0,this.cache={},this.delimiters=[],this._prev_delimiters=[]}a.prototype.pushPending=function(){var e=new n("text","",0);return e.content=this.pending,e.level=this.pendingLevel,this.tokens.push(e),this.pending="",e},a.prototype.push=function(e,r,t){this.pending&&this.pushPending();var s=new n(e,r,t),o=null;return t<0&&(this.level--,this.delimiters=this._prev_delimiters.pop()),s.level=this.level,t>0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],o={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(s),this.tokens_meta.push(o),s},a.prototype.scanDelims=function(e,r){var t,n,a,c,l,u,p,h,f,d=e,m=!0,_=!0,g=this.posMax,k=this.src.charCodeAt(e);for(t=e>0?this.src.charCodeAt(e-1):32;d<g&&this.src.charCodeAt(d)===k;)d++;return a=d-e,n=d<g?this.src.charCodeAt(d):32,p=i(t)||o(String.fromCharCode(t)),f=i(n)||o(String.fromCharCode(n)),u=s(t),(h=s(n))?m=!1:f&&(u||p||(m=!1)),u?_=!1:p&&(h||f||(_=!1)),r?(c=m,l=_):(c=m&&(!_||p),l=_&&(!m||f)),{can_open:c,can_close:l,length:a}},a.prototype.Token=n,r.exports=a},{"../common/utils":4,"../token":51}],48:[function(e,r,t){"use strict";function n(e,r){var t,n,s,o,i,a=[],c=r.length;for(t=0;t<c;t++)126===(s=r[t]).marker&&-1!==s.end&&(o=r[s.end],(i=e.tokens[s.token]).type="s_open",i.tag="s",i.nesting=1,i.markup="~~",i.content="",(i=e.tokens[o.token]).type="s_close",i.tag="s",i.nesting=-1,i.markup="~~",i.content="","text"===e.tokens[o.token-1].type&&"~"===e.tokens[o.token-1].content&&a.push(o.token-1));for(;a.length;){for(n=(t=a.pop())+1;n<e.tokens.length&&"s_close"===e.tokens[n].type;)n++;t!==--n&&(i=e.tokens[n],e.tokens[n]=e.tokens[t],e.tokens[t]=i)}}r.exports.tokenize=function(e,r){var t,n,s,o,i=e.pos,a=e.src.charCodeAt(i);if(r)return!1;if(126!==a)return!1;if(s=(n=e.scanDelims(e.pos,!0)).length,o=String.fromCharCode(a),s<2)return!1;for(s%2&&(e.push("text","",0).content=o,s--),t=0;t<s;t+=2)e.push("text","",0).content=o+o,e.delimiters.push({marker:a,length:0,jump:t,token:e.tokens.length-1,end:-1,open:n.can_open,close:n.can_close});return e.pos+=n.length,!0},r.exports.postProcess=function(e){var r,t=e.tokens_meta,s=e.tokens_meta.length;for(n(e,e.delimiters),r=0;r<s;r++)t[r]&&t[r].delimiters&&n(e,t[r].delimiters)}},{}],49:[function(e,r,t){"use strict";function n(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}r.exports=function(e,r){for(var t=e.pos;t<e.posMax&&!n(e.src.charCodeAt(t));)t++;return t!==e.pos&&(r||(e.pending+=e.src.slice(e.pos,t)),e.pos=t,!0)}},{}],50:[function(e,r,t){"use strict";r.exports=function(e){var r,t,n=0,s=e.tokens,o=e.tokens.length;for(r=t=0;r<o;r++)s[r].nesting<0&&n--,s[r].level=n,s[r].nesting>0&&n++,"text"===s[r].type&&r+1<o&&"text"===s[r+1].type?s[r+1].content=s[r].content+s[r+1].content:(r!==t&&(s[t]=s[r]),t++);r!==t&&(s.length=t)}},{}],51:[function(e,r,t){"use strict";function n(e,r,t){this.type=e,this.tag=r,this.attrs=null,this.map=null,this.nesting=t,this.level=0,this.children=null,this.content="",this.markup="",this.info="",this.meta=null,this.block=!1,this.hidden=!1}n.prototype.attrIndex=function(e){var r,t,n;if(!this.attrs)return-1;for(t=0,n=(r=this.attrs).length;t<n;t++)if(r[t][0]===e)return t;return-1},n.prototype.attrPush=function(e){this.attrs?this.attrs.push(e):this.attrs=[e]},n.prototype.attrSet=function(e,r){var t=this.attrIndex(e),n=[e,r];t<0?this.attrPush(n):this.attrs[t]=n},n.prototype.attrGet=function(e){var r=this.attrIndex(e),t=null;return r>=0&&(t=this.attrs[r][1]),t},n.prototype.attrJoin=function(e,r){var t=this.attrIndex(e);t<0?this.attrPush([e,r]):this.attrs[t][1]=this.attrs[t][1]+" "+r},r.exports=n},{}],52:[function(e,r,t){r.exports={Aacute:"\xc1",aacute:"\xe1",Abreve:"\u0102",abreve:"\u0103",ac:"\u223e",acd:"\u223f",acE:"\u223e\u0333",Acirc:"\xc2",acirc:"\xe2",acute:"\xb4",Acy:"\u0410",acy:"\u0430",AElig:"\xc6",aelig:"\xe6",af:"\u2061",Afr:"\ud835\udd04",afr:"\ud835\udd1e",Agrave:"\xc0",agrave:"\xe0",alefsym:"\u2135",aleph:"\u2135",Alpha:"\u0391",alpha:"\u03b1",Amacr:"\u0100",amacr:"\u0101",amalg:"\u2a3f",amp:"&",AMP:"&",andand:"\u2a55",And:"\u2a53",and:"\u2227",andd:"\u2a5c",andslope:"\u2a58",andv:"\u2a5a",ang:"\u2220",ange:"\u29a4",angle:"\u2220",angmsdaa:"\u29a8",angmsdab:"\u29a9",angmsdac:"\u29aa",angmsdad:"\u29ab",angmsdae:"\u29ac",angmsdaf:"\u29ad",angmsdag:"\u29ae",angmsdah:"\u29af",angmsd:"\u2221",angrt:"\u221f",angrtvb:"\u22be",angrtvbd:"\u299d",angsph:"\u2222",angst:"\xc5",angzarr:"\u237c",Aogon:"\u0104",aogon:"\u0105",Aopf:"\ud835\udd38",aopf:"\ud835\udd52",apacir:"\u2a6f",ap:"\u2248",apE:"\u2a70",ape:"\u224a",apid:"\u224b",apos:"'",ApplyFunction:"\u2061",approx:"\u2248",approxeq:"\u224a",Aring:"\xc5",aring:"\xe5",Ascr:"\ud835\udc9c",ascr:"\ud835\udcb6",Assign:"\u2254",ast:"*",asymp:"\u2248",asympeq:"\u224d",Atilde:"\xc3",atilde:"\xe3",Auml:"\xc4",auml:"\xe4",awconint:"\u2233",awint:"\u2a11",backcong:"\u224c",backepsilon:"\u03f6",backprime:"\u2035",backsim:"\u223d",backsimeq:"\u22cd",Backslash:"\u2216",Barv:"\u2ae7",barvee:"\u22bd",barwed:"\u2305",Barwed:"\u2306",barwedge:"\u2305",bbrk:"\u23b5",bbrktbrk:"\u23b6",bcong:"\u224c",Bcy:"\u0411",bcy:"\u0431",bdquo:"\u201e",becaus:"\u2235",because:"\u2235",Because:"\u2235",bemptyv:"\u29b0",bepsi:"\u03f6",bernou:"\u212c",Bernoullis:"\u212c",Beta:"\u0392",beta:"\u03b2",beth:"\u2136",between:"\u226c",Bfr:"\ud835\udd05",bfr:"\ud835\udd1f",bigcap:"\u22c2",bigcirc:"\u25ef",bigcup:"\u22c3",bigodot:"\u2a00",bigoplus:"\u2a01",bigotimes:"\u2a02",bigsqcup:"\u2a06",bigstar:"\u2605",bigtriangledown:"\u25bd",bigtriangleup:"\u25b3",biguplus:"\u2a04",bigvee:"\u22c1",bigwedge:"\u22c0",bkarow:"\u290d",blacklozenge:"\u29eb",blacksquare:"\u25aa",blacktriangle:"\u25b4",blacktriangledown:"\u25be",blacktriangleleft:"\u25c2",blacktriangleright:"\u25b8",blank:"\u2423",blk12:"\u2592",blk14:"\u2591",blk34:"\u2593",block:"\u2588",bne:"=\u20e5",bnequiv:"\u2261\u20e5",bNot:"\u2aed",bnot:"\u2310",Bopf:"\ud835\udd39",bopf:"\ud835\udd53",bot:"\u22a5",bottom:"\u22a5",bowtie:"\u22c8",boxbox:"\u29c9",boxdl:"\u2510",boxdL:"\u2555",boxDl:"\u2556",boxDL:"\u2557",boxdr:"\u250c",boxdR:"\u2552",boxDr:"\u2553",boxDR:"\u2554",boxh:"\u2500",boxH:"\u2550",boxhd:"\u252c",boxHd:"\u2564",boxhD:"\u2565",boxHD:"\u2566",boxhu:"\u2534",boxHu:"\u2567",boxhU:"\u2568",boxHU:"\u2569",boxminus:"\u229f",boxplus:"\u229e",boxtimes:"\u22a0",boxul:"\u2518",boxuL:"\u255b",boxUl:"\u255c",boxUL:"\u255d",boxur:"\u2514",boxuR:"\u2558",boxUr:"\u2559",boxUR:"\u255a",boxv:"\u2502",boxV:"\u2551",boxvh:"\u253c",boxvH:"\u256a",boxVh:"\u256b",boxVH:"\u256c",boxvl:"\u2524",boxvL:"\u2561",boxVl:"\u2562",boxVL:"\u2563",boxvr:"\u251c",boxvR:"\u255e",boxVr:"\u255f",boxVR:"\u2560",bprime:"\u2035",breve:"\u02d8",Breve:"\u02d8",brvbar:"\xa6",bscr:"\ud835\udcb7",Bscr:"\u212c",bsemi:"\u204f",bsim:"\u223d",bsime:"\u22cd",bsolb:"\u29c5",bsol:"\\",bsolhsub:"\u27c8",bull:"\u2022",bullet:"\u2022",bump:"\u224e",bumpE:"\u2aae",bumpe:"\u224f",Bumpeq:"\u224e",bumpeq:"\u224f",Cacute:"\u0106",cacute:"\u0107",capand:"\u2a44",capbrcup:"\u2a49",capcap:"\u2a4b",cap:"\u2229",Cap:"\u22d2",capcup:"\u2a47",capdot:"\u2a40",CapitalDifferentialD:"\u2145",caps:"\u2229\ufe00",caret:"\u2041",caron:"\u02c7",Cayleys:"\u212d",ccaps:"\u2a4d",Ccaron:"\u010c",ccaron:"\u010d",Ccedil:"\xc7",ccedil:"\xe7",Ccirc:"\u0108",ccirc:"\u0109",Cconint:"\u2230",ccups:"\u2a4c",ccupssm:"\u2a50",Cdot:"\u010a",cdot:"\u010b",cedil:"\xb8",Cedilla:"\xb8",cemptyv:"\u29b2",cent:"\xa2",centerdot:"\xb7",CenterDot:"\xb7",cfr:"\ud835\udd20",Cfr:"\u212d",CHcy:"\u0427",chcy:"\u0447",check:"\u2713",checkmark:"\u2713",Chi:"\u03a7",chi:"\u03c7",circ:"\u02c6",circeq:"\u2257",circlearrowleft:"\u21ba",circlearrowright:"\u21bb",circledast:"\u229b",circledcirc:"\u229a",circleddash:"\u229d",CircleDot:"\u2299",circledR:"\xae",circledS:"\u24c8",CircleMinus:"\u2296",CirclePlus:"\u2295",CircleTimes:"\u2297",cir:"\u25cb",cirE:"\u29c3",cire:"\u2257",cirfnint:"\u2a10",cirmid:"\u2aef",cirscir:"\u29c2",ClockwiseContourIntegral:"\u2232",CloseCurlyDoubleQuote:"\u201d",CloseCurlyQuote:"\u2019",clubs:"\u2663",clubsuit:"\u2663",colon:":",Colon:"\u2237",Colone:"\u2a74",colone:"\u2254",coloneq:"\u2254",comma:",",commat:"@",comp:"\u2201",compfn:"\u2218",complement:"\u2201",complexes:"\u2102",cong:"\u2245",congdot:"\u2a6d",Congruent:"\u2261",conint:"\u222e",Conint:"\u222f",ContourIntegral:"\u222e",copf:"\ud835\udd54",Copf:"\u2102",coprod:"\u2210",Coproduct:"\u2210",copy:"\xa9",COPY:"\xa9",copysr:"\u2117",CounterClockwiseContourIntegral:"\u2233",crarr:"\u21b5",cross:"\u2717",Cross:"\u2a2f",Cscr:"\ud835\udc9e",cscr:"\ud835\udcb8",csub:"\u2acf",csube:"\u2ad1",csup:"\u2ad0",csupe:"\u2ad2",ctdot:"\u22ef",cudarrl:"\u2938",cudarrr:"\u2935",cuepr:"\u22de",cuesc:"\u22df",cularr:"\u21b6",cularrp:"\u293d",cupbrcap:"\u2a48",cupcap:"\u2a46",CupCap:"\u224d",cup:"\u222a",Cup:"\u22d3",cupcup:"\u2a4a",cupdot:"\u228d",cupor:"\u2a45",cups:"\u222a\ufe00",curarr:"\u21b7",curarrm:"\u293c",curlyeqprec:"\u22de",curlyeqsucc:"\u22df",curlyvee:"\u22ce",curlywedge:"\u22cf",curren:"\xa4",curvearrowleft:"\u21b6",curvearrowright:"\u21b7",cuvee:"\u22ce",cuwed:"\u22cf",cwconint:"\u2232",cwint:"\u2231",cylcty:"\u232d",dagger:"\u2020",Dagger:"\u2021",daleth:"\u2138",darr:"\u2193",Darr:"\u21a1",dArr:"\u21d3",dash:"\u2010",Dashv:"\u2ae4",dashv:"\u22a3",dbkarow:"\u290f",dblac:"\u02dd",Dcaron:"\u010e",dcaron:"\u010f",Dcy:"\u0414",dcy:"\u0434",ddagger:"\u2021",ddarr:"\u21ca",DD:"\u2145",dd:"\u2146",DDotrahd:"\u2911",ddotseq:"\u2a77",deg:"\xb0",Del:"\u2207",Delta:"\u0394",delta:"\u03b4",demptyv:"\u29b1",dfisht:"\u297f",Dfr:"\ud835\udd07",dfr:"\ud835\udd21",dHar:"\u2965",dharl:"\u21c3",dharr:"\u21c2",DiacriticalAcute:"\xb4",DiacriticalDot:"\u02d9",DiacriticalDoubleAcute:"\u02dd",DiacriticalGrave:"`",DiacriticalTilde:"\u02dc",diam:"\u22c4",diamond:"\u22c4",Diamond:"\u22c4",diamondsuit:"\u2666",diams:"\u2666",die:"\xa8",DifferentialD:"\u2146",digamma:"\u03dd",disin:"\u22f2",div:"\xf7",divide:"\xf7",divideontimes:"\u22c7",divonx:"\u22c7",DJcy:"\u0402",djcy:"\u0452",dlcorn:"\u231e",dlcrop:"\u230d",dollar:"$",Dopf:"\ud835\udd3b",dopf:"\ud835\udd55",Dot:"\xa8",dot:"\u02d9",DotDot:"\u20dc",doteq:"\u2250",doteqdot:"\u2251",DotEqual:"\u2250",dotminus:"\u2238",dotplus:"\u2214",dotsquare:"\u22a1",doublebarwedge:"\u2306",DoubleContourIntegral:"\u222f",DoubleDot:"\xa8",DoubleDownArrow:"\u21d3",DoubleLeftArrow:"\u21d0",DoubleLeftRightArrow:"\u21d4",DoubleLeftTee:"\u2ae4",DoubleLongLeftArrow:"\u27f8",DoubleLongLeftRightArrow:"\u27fa",DoubleLongRightArrow:"\u27f9",DoubleRightArrow:"\u21d2",DoubleRightTee:"\u22a8",DoubleUpArrow:"\u21d1",DoubleUpDownArrow:"\u21d5",DoubleVerticalBar:"\u2225",DownArrowBar:"\u2913",downarrow:"\u2193",DownArrow:"\u2193",Downarrow:"\u21d3",DownArrowUpArrow:"\u21f5",DownBreve:"\u0311",downdownarrows:"\u21ca",downharpoonleft:"\u21c3",downharpoonright:"\u21c2",DownLeftRightVector:"\u2950",DownLeftTeeVector:"\u295e",DownLeftVectorBar:"\u2956",DownLeftVector:"\u21bd",DownRightTeeVector:"\u295f",DownRightVectorBar:"\u2957",DownRightVector:"\u21c1",DownTeeArrow:"\u21a7",DownTee:"\u22a4",drbkarow:"\u2910",drcorn:"\u231f",drcrop:"\u230c",Dscr:"\ud835\udc9f",dscr:"\ud835\udcb9",DScy:"\u0405",dscy:"\u0455",dsol:"\u29f6",Dstrok:"\u0110",dstrok:"\u0111",dtdot:"\u22f1",dtri:"\u25bf",dtrif:"\u25be",duarr:"\u21f5",duhar:"\u296f",dwangle:"\u29a6",DZcy:"\u040f",dzcy:"\u045f",dzigrarr:"\u27ff",Eacute:"\xc9",eacute:"\xe9",easter:"\u2a6e",Ecaron:"\u011a",ecaron:"\u011b",Ecirc:"\xca",ecirc:"\xea",ecir:"\u2256",ecolon:"\u2255",Ecy:"\u042d",ecy:"\u044d",eDDot:"\u2a77",Edot:"\u0116",edot:"\u0117",eDot:"\u2251",ee:"\u2147",efDot:"\u2252",Efr:"\ud835\udd08",efr:"\ud835\udd22",eg:"\u2a9a",Egrave:"\xc8",egrave:"\xe8",egs:"\u2a96",egsdot:"\u2a98",el:"\u2a99",Element:"\u2208",elinters:"\u23e7",ell:"\u2113",els:"\u2a95",elsdot:"\u2a97",Emacr:"\u0112",emacr:"\u0113",empty:"\u2205",emptyset:"\u2205",EmptySmallSquare:"\u25fb",emptyv:"\u2205",EmptyVerySmallSquare:"\u25ab",emsp13:"\u2004",emsp14:"\u2005",emsp:"\u2003",ENG:"\u014a",eng:"\u014b",ensp:"\u2002",Eogon:"\u0118",eogon:"\u0119",Eopf:"\ud835\udd3c",eopf:"\ud835\udd56",epar:"\u22d5",eparsl:"\u29e3",eplus:"\u2a71",epsi:"\u03b5",Epsilon:"\u0395",epsilon:"\u03b5",epsiv:"\u03f5",eqcirc:"\u2256",eqcolon:"\u2255",eqsim:"\u2242",eqslantgtr:"\u2a96",eqslantless:"\u2a95",Equal:"\u2a75",equals:"=",EqualTilde:"\u2242",equest:"\u225f",Equilibrium:"\u21cc",equiv:"\u2261",equivDD:"\u2a78",eqvparsl:"\u29e5",erarr:"\u2971",erDot:"\u2253",escr:"\u212f",Escr:"\u2130",esdot:"\u2250",Esim:"\u2a73",esim:"\u2242",Eta:"\u0397",eta:"\u03b7",ETH:"\xd0",eth:"\xf0",Euml:"\xcb",euml:"\xeb",euro:"\u20ac",excl:"!",exist:"\u2203",Exists:"\u2203",expectation:"\u2130",exponentiale:"\u2147",ExponentialE:"\u2147",fallingdotseq:"\u2252",Fcy:"\u0424",fcy:"\u0444",female:"\u2640",ffilig:"\ufb03",fflig:"\ufb00",ffllig:"\ufb04",Ffr:"\ud835\udd09",ffr:"\ud835\udd23",filig:"\ufb01",FilledSmallSquare:"\u25fc",FilledVerySmallSquare:"\u25aa",fjlig:"fj",flat:"\u266d",fllig:"\ufb02",fltns:"\u25b1",fnof:"\u0192",Fopf:"\ud835\udd3d",fopf:"\ud835\udd57",forall:"\u2200",ForAll:"\u2200",fork:"\u22d4",forkv:"\u2ad9",Fouriertrf:"\u2131",fpartint:"\u2a0d",frac12:"\xbd",frac13:"\u2153",frac14:"\xbc",frac15:"\u2155",frac16:"\u2159",frac18:"\u215b",frac23:"\u2154",frac25:"\u2156",frac34:"\xbe",frac35:"\u2157",frac38:"\u215c",frac45:"\u2158",frac56:"\u215a",frac58:"\u215d",frac78:"\u215e",frasl:"\u2044",frown:"\u2322",fscr:"\ud835\udcbb",Fscr:"\u2131",gacute:"\u01f5",Gamma:"\u0393",gamma:"\u03b3",Gammad:"\u03dc",gammad:"\u03dd",gap:"\u2a86",Gbreve:"\u011e",gbreve:"\u011f",Gcedil:"\u0122",Gcirc:"\u011c",gcirc:"\u011d",Gcy:"\u0413",gcy:"\u0433",Gdot:"\u0120",gdot:"\u0121",ge:"\u2265",gE:"\u2267",gEl:"\u2a8c",gel:"\u22db",geq:"\u2265",geqq:"\u2267",geqslant:"\u2a7e",gescc:"\u2aa9",ges:"\u2a7e",gesdot:"\u2a80",gesdoto:"\u2a82",gesdotol:"\u2a84",gesl:"\u22db\ufe00",gesles:"\u2a94",Gfr:"\ud835\udd0a",gfr:"\ud835\udd24",gg:"\u226b",Gg:"\u22d9",ggg:"\u22d9",gimel:"\u2137",GJcy:"\u0403",gjcy:"\u0453",gla:"\u2aa5",gl:"\u2277",glE:"\u2a92",glj:"\u2aa4",gnap:"\u2a8a",gnapprox:"\u2a8a",gne:"\u2a88",gnE:"\u2269",gneq:"\u2a88",gneqq:"\u2269",gnsim:"\u22e7",Gopf:"\ud835\udd3e",gopf:"\ud835\udd58",grave:"`",GreaterEqual:"\u2265",GreaterEqualLess:"\u22db",GreaterFullEqual:"\u2267",GreaterGreater:"\u2aa2",GreaterLess:"\u2277",GreaterSlantEqual:"\u2a7e",GreaterTilde:"\u2273",Gscr:"\ud835\udca2",gscr:"\u210a",gsim:"\u2273",gsime:"\u2a8e",gsiml:"\u2a90",gtcc:"\u2aa7",gtcir:"\u2a7a",gt:">",GT:">",Gt:"\u226b",gtdot:"\u22d7",gtlPar:"\u2995",gtquest:"\u2a7c",gtrapprox:"\u2a86",gtrarr:"\u2978",gtrdot:"\u22d7",gtreqless:"\u22db",gtreqqless:"\u2a8c",gtrless:"\u2277",gtrsim:"\u2273",gvertneqq:"\u2269\ufe00",gvnE:"\u2269\ufe00",Hacek:"\u02c7",hairsp:"\u200a",half:"\xbd",hamilt:"\u210b",HARDcy:"\u042a",hardcy:"\u044a",harrcir:"\u2948",harr:"\u2194",hArr:"\u21d4",harrw:"\u21ad",Hat:"^",hbar:"\u210f",Hcirc:"\u0124",hcirc:"\u0125",hearts:"\u2665",heartsuit:"\u2665",hellip:"\u2026",hercon:"\u22b9",hfr:"\ud835\udd25",Hfr:"\u210c",HilbertSpace:"\u210b",hksearow:"\u2925",hkswarow:"\u2926",hoarr:"\u21ff",homtht:"\u223b",hookleftarrow:"\u21a9",hookrightarrow:"\u21aa",hopf:"\ud835\udd59",Hopf:"\u210d",horbar:"\u2015",HorizontalLine:"\u2500",hscr:"\ud835\udcbd",Hscr:"\u210b",hslash:"\u210f",Hstrok:"\u0126",hstrok:"\u0127",HumpDownHump:"\u224e",HumpEqual:"\u224f",hybull:"\u2043",hyphen:"\u2010",Iacute:"\xcd",iacute:"\xed",ic:"\u2063",Icirc:"\xce",icirc:"\xee",Icy:"\u0418",icy:"\u0438",Idot:"\u0130",IEcy:"\u0415",iecy:"\u0435",iexcl:"\xa1",iff:"\u21d4",ifr:"\ud835\udd26",Ifr:"\u2111",Igrave:"\xcc",igrave:"\xec",ii:"\u2148",iiiint:"\u2a0c",iiint:"\u222d",iinfin:"\u29dc",iiota:"\u2129",IJlig:"\u0132",ijlig:"\u0133",Imacr:"\u012a",imacr:"\u012b",image:"\u2111",ImaginaryI:"\u2148",imagline:"\u2110",imagpart:"\u2111",imath:"\u0131",Im:"\u2111",imof:"\u22b7",imped:"\u01b5",Implies:"\u21d2",incare:"\u2105",in:"\u2208",infin:"\u221e",infintie:"\u29dd",inodot:"\u0131",intcal:"\u22ba",int:"\u222b",Int:"\u222c",integers:"\u2124",Integral:"\u222b",intercal:"\u22ba",Intersection:"\u22c2",intlarhk:"\u2a17",intprod:"\u2a3c",InvisibleComma:"\u2063",InvisibleTimes:"\u2062",IOcy:"\u0401",iocy:"\u0451",Iogon:"\u012e",iogon:"\u012f",Iopf:"\ud835\udd40",iopf:"\ud835\udd5a",Iota:"\u0399",iota:"\u03b9",iprod:"\u2a3c",iquest:"\xbf",iscr:"\ud835\udcbe",Iscr:"\u2110",isin:"\u2208",isindot:"\u22f5",isinE:"\u22f9",isins:"\u22f4",isinsv:"\u22f3",isinv:"\u2208",it:"\u2062",Itilde:"\u0128",itilde:"\u0129",Iukcy:"\u0406",iukcy:"\u0456",Iuml:"\xcf",iuml:"\xef",Jcirc:"\u0134",jcirc:"\u0135",Jcy:"\u0419",jcy:"\u0439",Jfr:"\ud835\udd0d",jfr:"\ud835\udd27",jmath:"\u0237",Jopf:"\ud835\udd41",jopf:"\ud835\udd5b",Jscr:"\ud835\udca5",jscr:"\ud835\udcbf",Jsercy:"\u0408",jsercy:"\u0458",Jukcy:"\u0404",jukcy:"\u0454",Kappa:"\u039a",kappa:"\u03ba",kappav:"\u03f0",Kcedil:"\u0136",kcedil:"\u0137",Kcy:"\u041a",kcy:"\u043a",Kfr:"\ud835\udd0e",kfr:"\ud835\udd28",kgreen:"\u0138",KHcy:"\u0425",khcy:"\u0445",KJcy:"\u040c",kjcy:"\u045c",Kopf:"\ud835\udd42",kopf:"\ud835\udd5c",Kscr:"\ud835\udca6",kscr:"\ud835\udcc0",lAarr:"\u21da",Lacute:"\u0139",lacute:"\u013a",laemptyv:"\u29b4",lagran:"\u2112",Lambda:"\u039b",lambda:"\u03bb",lang:"\u27e8",Lang:"\u27ea",langd:"\u2991",langle:"\u27e8",lap:"\u2a85",Laplacetrf:"\u2112",laquo:"\xab",larrb:"\u21e4",larrbfs:"\u291f",larr:"\u2190",Larr:"\u219e",lArr:"\u21d0",larrfs:"\u291d",larrhk:"\u21a9",larrlp:"\u21ab",larrpl:"\u2939",larrsim:"\u2973",larrtl:"\u21a2",latail:"\u2919",lAtail:"\u291b",lat:"\u2aab",late:"\u2aad",lates:"\u2aad\ufe00",lbarr:"\u290c",lBarr:"\u290e",lbbrk:"\u2772",lbrace:"{",lbrack:"[",lbrke:"\u298b",lbrksld:"\u298f",lbrkslu:"\u298d",Lcaron:"\u013d",lcaron:"\u013e",Lcedil:"\u013b",lcedil:"\u013c",lceil:"\u2308",lcub:"{",Lcy:"\u041b",lcy:"\u043b",ldca:"\u2936",ldquo:"\u201c",ldquor:"\u201e",ldrdhar:"\u2967",ldrushar:"\u294b",ldsh:"\u21b2",le:"\u2264",lE:"\u2266",LeftAngleBracket:"\u27e8",LeftArrowBar:"\u21e4",leftarrow:"\u2190",LeftArrow:"\u2190",Leftarrow:"\u21d0",LeftArrowRightArrow:"\u21c6",leftarrowtail:"\u21a2",LeftCeiling:"\u2308",LeftDoubleBracket:"\u27e6",LeftDownTeeVector:"\u2961",LeftDownVectorBar:"\u2959",LeftDownVector:"\u21c3",LeftFloor:"\u230a",leftharpoondown:"\u21bd",leftharpoonup:"\u21bc",leftleftarrows:"\u21c7",leftrightarrow:"\u2194",LeftRightArrow:"\u2194",Leftrightarrow:"\u21d4",leftrightarrows:"\u21c6",leftrightharpoons:"\u21cb",leftrightsquigarrow:"\u21ad",LeftRightVector:"\u294e",LeftTeeArrow:"\u21a4",LeftTee:"\u22a3",LeftTeeVector:"\u295a",leftthreetimes:"\u22cb",LeftTriangleBar:"\u29cf",LeftTriangle:"\u22b2",LeftTriangleEqual:"\u22b4",LeftUpDownVector:"\u2951",LeftUpTeeVector:"\u2960",LeftUpVectorBar:"\u2958",LeftUpVector:"\u21bf",LeftVectorBar:"\u2952",LeftVector:"\u21bc",lEg:"\u2a8b",leg:"\u22da",leq:"\u2264",leqq:"\u2266",leqslant:"\u2a7d",lescc:"\u2aa8",les:"\u2a7d",lesdot:"\u2a7f",lesdoto:"\u2a81",lesdotor:"\u2a83",lesg:"\u22da\ufe00",lesges:"\u2a93",lessapprox:"\u2a85",lessdot:"\u22d6",lesseqgtr:"\u22da",lesseqqgtr:"\u2a8b",LessEqualGreater:"\u22da",LessFullEqual:"\u2266",LessGreater:"\u2276",lessgtr:"\u2276",LessLess:"\u2aa1",lesssim:"\u2272",LessSlantEqual:"\u2a7d",LessTilde:"\u2272",lfisht:"\u297c",lfloor:"\u230a",Lfr:"\ud835\udd0f",lfr:"\ud835\udd29",lg:"\u2276",lgE:"\u2a91",lHar:"\u2962",lhard:"\u21bd",lharu:"\u21bc",lharul:"\u296a",lhblk:"\u2584",LJcy:"\u0409",ljcy:"\u0459",llarr:"\u21c7",ll:"\u226a",Ll:"\u22d8",llcorner:"\u231e",Lleftarrow:"\u21da",llhard:"\u296b",lltri:"\u25fa",Lmidot:"\u013f",lmidot:"\u0140",lmoustache:"\u23b0",lmoust:"\u23b0",lnap:"\u2a89",lnapprox:"\u2a89",lne:"\u2a87",lnE:"\u2268",lneq:"\u2a87",lneqq:"\u2268",lnsim:"\u22e6",loang:"\u27ec",loarr:"\u21fd",lobrk:"\u27e6",longleftarrow:"\u27f5",LongLeftArrow:"\u27f5",Longleftarrow:"\u27f8",longleftrightarrow:"\u27f7",LongLeftRightArrow:"\u27f7",Longleftrightarrow:"\u27fa",longmapsto:"\u27fc",longrightarrow:"\u27f6",LongRightArrow:"\u27f6",Longrightarrow:"\u27f9",looparrowleft:"\u21ab",looparrowright:"\u21ac",lopar:"\u2985",Lopf:"\ud835\udd43",lopf:"\ud835\udd5d",loplus:"\u2a2d",lotimes:"\u2a34",lowast:"\u2217",lowbar:"_",LowerLeftArrow:"\u2199",LowerRightArrow:"\u2198",loz:"\u25ca",lozenge:"\u25ca",lozf:"\u29eb",lpar:"(",lparlt:"\u2993",lrarr:"\u21c6",lrcorner:"\u231f",lrhar:"\u21cb",lrhard:"\u296d",lrm:"\u200e",lrtri:"\u22bf",lsaquo:"\u2039",lscr:"\ud835\udcc1",Lscr:"\u2112",lsh:"\u21b0",Lsh:"\u21b0",lsim:"\u2272",lsime:"\u2a8d",lsimg:"\u2a8f",lsqb:"[",lsquo:"\u2018",lsquor:"\u201a",Lstrok:"\u0141",lstrok:"\u0142",ltcc:"\u2aa6",ltcir:"\u2a79",lt:"<",LT:"<",Lt:"\u226a",ltdot:"\u22d6",lthree:"\u22cb",ltimes:"\u22c9",ltlarr:"\u2976",ltquest:"\u2a7b",ltri:"\u25c3",ltrie:"\u22b4",ltrif:"\u25c2",ltrPar:"\u2996",lurdshar:"\u294a",luruhar:"\u2966",lvertneqq:"\u2268\ufe00",lvnE:"\u2268\ufe00",macr:"\xaf",male:"\u2642",malt:"\u2720",maltese:"\u2720",Map:"\u2905",map:"\u21a6",mapsto:"\u21a6",mapstodown:"\u21a7",mapstoleft:"\u21a4",mapstoup:"\u21a5",marker:"\u25ae",mcomma:"\u2a29",Mcy:"\u041c",mcy:"\u043c",mdash:"\u2014",mDDot:"\u223a",measuredangle:"\u2221",MediumSpace:"\u205f",Mellintrf:"\u2133",Mfr:"\ud835\udd10",mfr:"\ud835\udd2a",mho:"\u2127",micro:"\xb5",midast:"*",midcir:"\u2af0",mid:"\u2223",middot:"\xb7",minusb:"\u229f",minus:"\u2212",minusd:"\u2238",minusdu:"\u2a2a",MinusPlus:"\u2213",mlcp:"\u2adb",mldr:"\u2026",mnplus:"\u2213",models:"\u22a7",Mopf:"\ud835\udd44",mopf:"\ud835\udd5e",mp:"\u2213",mscr:"\ud835\udcc2",Mscr:"\u2133",mstpos:"\u223e",Mu:"\u039c",mu:"\u03bc",multimap:"\u22b8",mumap:"\u22b8",nabla:"\u2207",Nacute:"\u0143",nacute:"\u0144",nang:"\u2220\u20d2",nap:"\u2249",napE:"\u2a70\u0338",napid:"\u224b\u0338",napos:"\u0149",napprox:"\u2249",natural:"\u266e",naturals:"\u2115",natur:"\u266e",nbsp:"\xa0",nbump:"\u224e\u0338",nbumpe:"\u224f\u0338",ncap:"\u2a43",Ncaron:"\u0147",ncaron:"\u0148",Ncedil:"\u0145",ncedil:"\u0146",ncong:"\u2247",ncongdot:"\u2a6d\u0338",ncup:"\u2a42",Ncy:"\u041d",ncy:"\u043d",ndash:"\u2013",nearhk:"\u2924",nearr:"\u2197",neArr:"\u21d7",nearrow:"\u2197",ne:"\u2260",nedot:"\u2250\u0338",NegativeMediumSpace:"\u200b",NegativeThickSpace:"\u200b",NegativeThinSpace:"\u200b",NegativeVeryThinSpace:"\u200b",nequiv:"\u2262",nesear:"\u2928",nesim:"\u2242\u0338",NestedGreaterGreater:"\u226b",NestedLessLess:"\u226a",NewLine:"\n",nexist:"\u2204",nexists:"\u2204",Nfr:"\ud835\udd11",nfr:"\ud835\udd2b",ngE:"\u2267\u0338",nge:"\u2271",ngeq:"\u2271",ngeqq:"\u2267\u0338",ngeqslant:"\u2a7e\u0338",nges:"\u2a7e\u0338",nGg:"\u22d9\u0338",ngsim:"\u2275",nGt:"\u226b\u20d2",ngt:"\u226f",ngtr:"\u226f",nGtv:"\u226b\u0338",nharr:"\u21ae",nhArr:"\u21ce",nhpar:"\u2af2",ni:"\u220b",nis:"\u22fc",nisd:"\u22fa",niv:"\u220b",NJcy:"\u040a",njcy:"\u045a",nlarr:"\u219a",nlArr:"\u21cd",nldr:"\u2025",nlE:"\u2266\u0338",nle:"\u2270",nleftarrow:"\u219a",nLeftarrow:"\u21cd",nleftrightarrow:"\u21ae",nLeftrightarrow:"\u21ce",nleq:"\u2270",nleqq:"\u2266\u0338",nleqslant:"\u2a7d\u0338",nles:"\u2a7d\u0338",nless:"\u226e",nLl:"\u22d8\u0338",nlsim:"\u2274",nLt:"\u226a\u20d2",nlt:"\u226e",nltri:"\u22ea",nltrie:"\u22ec",nLtv:"\u226a\u0338",nmid:"\u2224",NoBreak:"\u2060",NonBreakingSpace:"\xa0",nopf:"\ud835\udd5f",Nopf:"\u2115",Not:"\u2aec",not:"\xac",NotCongruent:"\u2262",NotCupCap:"\u226d",NotDoubleVerticalBar:"\u2226",NotElement:"\u2209",NotEqual:"\u2260",NotEqualTilde:"\u2242\u0338",NotExists:"\u2204",NotGreater:"\u226f",NotGreaterEqual:"\u2271",NotGreaterFullEqual:"\u2267\u0338",NotGreaterGreater:"\u226b\u0338",NotGreaterLess:"\u2279",NotGreaterSlantEqual:"\u2a7e\u0338",NotGreaterTilde:"\u2275",NotHumpDownHump:"\u224e\u0338",NotHumpEqual:"\u224f\u0338",notin:"\u2209",notindot:"\u22f5\u0338",notinE:"\u22f9\u0338",notinva:"\u2209",notinvb:"\u22f7",notinvc:"\u22f6",NotLeftTriangleBar:"\u29cf\u0338",NotLeftTriangle:"\u22ea",NotLeftTriangleEqual:"\u22ec",NotLess:"\u226e",NotLessEqual:"\u2270",NotLessGreater:"\u2278",NotLessLess:"\u226a\u0338",NotLessSlantEqual:"\u2a7d\u0338",NotLessTilde:"\u2274",NotNestedGreaterGreater:"\u2aa2\u0338",NotNestedLessLess:"\u2aa1\u0338",notni:"\u220c",notniva:"\u220c",notnivb:"\u22fe",notnivc:"\u22fd",NotPrecedes:"\u2280",NotPrecedesEqual:"\u2aaf\u0338",NotPrecedesSlantEqual:"\u22e0",NotReverseElement:"\u220c",NotRightTriangleBar:"\u29d0\u0338",NotRightTriangle:"\u22eb",NotRightTriangleEqual:"\u22ed",NotSquareSubset:"\u228f\u0338",NotSquareSubsetEqual:"\u22e2",NotSquareSuperset:"\u2290\u0338",NotSquareSupersetEqual:"\u22e3",NotSubset:"\u2282\u20d2",NotSubsetEqual:"\u2288",NotSucceeds:"\u2281",NotSucceedsEqual:"\u2ab0\u0338",NotSucceedsSlantEqual:"\u22e1",NotSucceedsTilde:"\u227f\u0338",NotSuperset:"\u2283\u20d2",NotSupersetEqual:"\u2289",NotTilde:"\u2241",NotTildeEqual:"\u2244",NotTildeFullEqual:"\u2247",NotTildeTilde:"\u2249",NotVerticalBar:"\u2224",nparallel:"\u2226",npar:"\u2226",nparsl:"\u2afd\u20e5",npart:"\u2202\u0338",npolint:"\u2a14",npr:"\u2280",nprcue:"\u22e0",nprec:"\u2280",npreceq:"\u2aaf\u0338",npre:"\u2aaf\u0338",nrarrc:"\u2933\u0338",nrarr:"\u219b",nrArr:"\u21cf",nrarrw:"\u219d\u0338",nrightarrow:"\u219b",nRightarrow:"\u21cf",nrtri:"\u22eb",nrtrie:"\u22ed",nsc:"\u2281",nsccue:"\u22e1",nsce:"\u2ab0\u0338",Nscr:"\ud835\udca9",nscr:"\ud835\udcc3",nshortmid:"\u2224",nshortparallel:"\u2226",nsim:"\u2241",nsime:"\u2244",nsimeq:"\u2244",nsmid:"\u2224",nspar:"\u2226",nsqsube:"\u22e2",nsqsupe:"\u22e3",nsub:"\u2284",nsubE:"\u2ac5\u0338",nsube:"\u2288",nsubset:"\u2282\u20d2",nsubseteq:"\u2288",nsubseteqq:"\u2ac5\u0338",nsucc:"\u2281",nsucceq:"\u2ab0\u0338",nsup:"\u2285",nsupE:"\u2ac6\u0338",nsupe:"\u2289",nsupset:"\u2283\u20d2",nsupseteq:"\u2289",nsupseteqq:"\u2ac6\u0338",ntgl:"\u2279",Ntilde:"\xd1",ntilde:"\xf1",ntlg:"\u2278",ntriangleleft:"\u22ea",ntrianglelefteq:"\u22ec",ntriangleright:"\u22eb",ntrianglerighteq:"\u22ed",Nu:"\u039d",nu:"\u03bd",num:"#",numero:"\u2116",numsp:"\u2007",nvap:"\u224d\u20d2",nvdash:"\u22ac",nvDash:"\u22ad",nVdash:"\u22ae",nVDash:"\u22af",nvge:"\u2265\u20d2",nvgt:">\u20d2",nvHarr:"\u2904",nvinfin:"\u29de",nvlArr:"\u2902",nvle:"\u2264\u20d2",nvlt:"<\u20d2",nvltrie:"\u22b4\u20d2",nvrArr:"\u2903",nvrtrie:"\u22b5\u20d2",nvsim:"\u223c\u20d2",nwarhk:"\u2923",nwarr:"\u2196",nwArr:"\u21d6",nwarrow:"\u2196",nwnear:"\u2927",Oacute:"\xd3",oacute:"\xf3",oast:"\u229b",Ocirc:"\xd4",ocirc:"\xf4",ocir:"\u229a",Ocy:"\u041e",ocy:"\u043e",odash:"\u229d",Odblac:"\u0150",odblac:"\u0151",odiv:"\u2a38",odot:"\u2299",odsold:"\u29bc",OElig:"\u0152",oelig:"\u0153",ofcir:"\u29bf",Ofr:"\ud835\udd12",ofr:"\ud835\udd2c",ogon:"\u02db",Ograve:"\xd2",ograve:"\xf2",ogt:"\u29c1",ohbar:"\u29b5",ohm:"\u03a9",oint:"\u222e",olarr:"\u21ba",olcir:"\u29be",olcross:"\u29bb",oline:"\u203e",olt:"\u29c0",Omacr:"\u014c",omacr:"\u014d",Omega:"\u03a9",omega:"\u03c9",Omicron:"\u039f",omicron:"\u03bf",omid:"\u29b6",ominus:"\u2296",Oopf:"\ud835\udd46",oopf:"\ud835\udd60",opar:"\u29b7",OpenCurlyDoubleQuote:"\u201c",OpenCurlyQuote:"\u2018",operp:"\u29b9",oplus:"\u2295",orarr:"\u21bb",Or:"\u2a54",or:"\u2228",ord:"\u2a5d",order:"\u2134",orderof:"\u2134",ordf:"\xaa",ordm:"\xba",origof:"\u22b6",oror:"\u2a56",orslope:"\u2a57",orv:"\u2a5b",oS:"\u24c8",Oscr:"\ud835\udcaa",oscr:"\u2134",Oslash:"\xd8",oslash:"\xf8",osol:"\u2298",Otilde:"\xd5",otilde:"\xf5",otimesas:"\u2a36",Otimes:"\u2a37",otimes:"\u2297",Ouml:"\xd6",ouml:"\xf6",ovbar:"\u233d",OverBar:"\u203e",OverBrace:"\u23de",OverBracket:"\u23b4",OverParenthesis:"\u23dc",para:"\xb6",parallel:"\u2225",par:"\u2225",parsim:"\u2af3",parsl:"\u2afd",part:"\u2202",PartialD:"\u2202",Pcy:"\u041f",pcy:"\u043f",percnt:"%",period:".",permil:"\u2030",perp:"\u22a5",pertenk:"\u2031",Pfr:"\ud835\udd13",pfr:"\ud835\udd2d",Phi:"\u03a6",phi:"\u03c6",phiv:"\u03d5",phmmat:"\u2133",phone:"\u260e",Pi:"\u03a0",pi:"\u03c0",pitchfork:"\u22d4",piv:"\u03d6",planck:"\u210f",planckh:"\u210e",plankv:"\u210f",plusacir:"\u2a23",plusb:"\u229e",pluscir:"\u2a22",plus:"+",plusdo:"\u2214",plusdu:"\u2a25",pluse:"\u2a72",PlusMinus:"\xb1",plusmn:"\xb1",plussim:"\u2a26",plustwo:"\u2a27",pm:"\xb1",Poincareplane:"\u210c",pointint:"\u2a15",popf:"\ud835\udd61",Popf:"\u2119",pound:"\xa3",prap:"\u2ab7",Pr:"\u2abb",pr:"\u227a",prcue:"\u227c",precapprox:"\u2ab7",prec:"\u227a",preccurlyeq:"\u227c",Precedes:"\u227a",PrecedesEqual:"\u2aaf",PrecedesSlantEqual:"\u227c",PrecedesTilde:"\u227e",preceq:"\u2aaf",precnapprox:"\u2ab9",precneqq:"\u2ab5",precnsim:"\u22e8",pre:"\u2aaf",prE:"\u2ab3",precsim:"\u227e",prime:"\u2032",Prime:"\u2033",primes:"\u2119",prnap:"\u2ab9",prnE:"\u2ab5",prnsim:"\u22e8",prod:"\u220f",Product:"\u220f",profalar:"\u232e",profline:"\u2312",profsurf:"\u2313",prop:"\u221d",Proportional:"\u221d",Proportion:"\u2237",propto:"\u221d",prsim:"\u227e",prurel:"\u22b0",Pscr:"\ud835\udcab",pscr:"\ud835\udcc5",Psi:"\u03a8",psi:"\u03c8",puncsp:"\u2008",Qfr:"\ud835\udd14",qfr:"\ud835\udd2e",qint:"\u2a0c",qopf:"\ud835\udd62",Qopf:"\u211a",qprime:"\u2057",Qscr:"\ud835\udcac",qscr:"\ud835\udcc6",quaternions:"\u210d",quatint:"\u2a16",quest:"?",questeq:"\u225f",quot:'"',QUOT:'"',rAarr:"\u21db",race:"\u223d\u0331",Racute:"\u0154",racute:"\u0155",radic:"\u221a",raemptyv:"\u29b3",rang:"\u27e9",Rang:"\u27eb",rangd:"\u2992",range:"\u29a5",rangle:"\u27e9",raquo:"\xbb",rarrap:"\u2975",rarrb:"\u21e5",rarrbfs:"\u2920",rarrc:"\u2933",rarr:"\u2192",Rarr:"\u21a0",rArr:"\u21d2",rarrfs:"\u291e",rarrhk:"\u21aa",rarrlp:"\u21ac",rarrpl:"\u2945",rarrsim:"\u2974",Rarrtl:"\u2916",rarrtl:"\u21a3",rarrw:"\u219d",ratail:"\u291a",rAtail:"\u291c",ratio:"\u2236",rationals:"\u211a",rbarr:"\u290d",rBarr:"\u290f",RBarr:"\u2910",rbbrk:"\u2773",rbrace:"}",rbrack:"]",rbrke:"\u298c",rbrksld:"\u298e",rbrkslu:"\u2990",Rcaron:"\u0158",rcaron:"\u0159",Rcedil:"\u0156",rcedil:"\u0157",rceil:"\u2309",rcub:"}",Rcy:"\u0420",rcy:"\u0440",rdca:"\u2937",rdldhar:"\u2969",rdquo:"\u201d",rdquor:"\u201d",rdsh:"\u21b3",real:"\u211c",realine:"\u211b",realpart:"\u211c",reals:"\u211d",Re:"\u211c",rect:"\u25ad",reg:"\xae",REG:"\xae",ReverseElement:"\u220b",ReverseEquilibrium:"\u21cb",ReverseUpEquilibrium:"\u296f",rfisht:"\u297d",rfloor:"\u230b",rfr:"\ud835\udd2f",Rfr:"\u211c",rHar:"\u2964",rhard:"\u21c1",rharu:"\u21c0",rharul:"\u296c",Rho:"\u03a1",rho:"\u03c1",rhov:"\u03f1",RightAngleBracket:"\u27e9",RightArrowBar:"\u21e5",rightarrow:"\u2192",RightArrow:"\u2192",Rightarrow:"\u21d2",RightArrowLeftArrow:"\u21c4",rightarrowtail:"\u21a3",RightCeiling:"\u2309",RightDoubleBracket:"\u27e7",RightDownTeeVector:"\u295d",RightDownVectorBar:"\u2955",RightDownVector:"\u21c2",RightFloor:"\u230b",rightharpoondown:"\u21c1",rightharpoonup:"\u21c0",rightleftarrows:"\u21c4",rightleftharpoons:"\u21cc",rightrightarrows:"\u21c9",rightsquigarrow:"\u219d",RightTeeArrow:"\u21a6",RightTee:"\u22a2",RightTeeVector:"\u295b",rightthreetimes:"\u22cc",RightTriangleBar:"\u29d0",RightTriangle:"\u22b3",RightTriangleEqual:"\u22b5",RightUpDownVector:"\u294f",RightUpTeeVector:"\u295c",RightUpVectorBar:"\u2954",RightUpVector:"\u21be",RightVectorBar:"\u2953",RightVector:"\u21c0",ring:"\u02da",risingdotseq:"\u2253",rlarr:"\u21c4",rlhar:"\u21cc",rlm:"\u200f",rmoustache:"\u23b1",rmoust:"\u23b1",rnmid:"\u2aee",roang:"\u27ed",roarr:"\u21fe",robrk:"\u27e7",ropar:"\u2986",ropf:"\ud835\udd63",Ropf:"\u211d",roplus:"\u2a2e",rotimes:"\u2a35",RoundImplies:"\u2970",rpar:")",rpargt:"\u2994",rppolint:"\u2a12",rrarr:"\u21c9",Rrightarrow:"\u21db",rsaquo:"\u203a",rscr:"\ud835\udcc7",Rscr:"\u211b",rsh:"\u21b1",Rsh:"\u21b1",rsqb:"]",rsquo:"\u2019",rsquor:"\u2019",rthree:"\u22cc",rtimes:"\u22ca",rtri:"\u25b9",rtrie:"\u22b5",rtrif:"\u25b8",rtriltri:"\u29ce",RuleDelayed:"\u29f4",ruluhar:"\u2968",rx:"\u211e",Sacute:"\u015a",sacute:"\u015b",sbquo:"\u201a",scap:"\u2ab8",Scaron:"\u0160",scaron:"\u0161",Sc:"\u2abc",sc:"\u227b",sccue:"\u227d",sce:"\u2ab0",scE:"\u2ab4",Scedil:"\u015e",scedil:"\u015f",Scirc:"\u015c",scirc:"\u015d",scnap:"\u2aba",scnE:"\u2ab6",scnsim:"\u22e9",scpolint:"\u2a13",scsim:"\u227f",Scy:"\u0421",scy:"\u0441",sdotb:"\u22a1",sdot:"\u22c5",sdote:"\u2a66",searhk:"\u2925",searr:"\u2198",seArr:"\u21d8",searrow:"\u2198",sect:"\xa7",semi:";",seswar:"\u2929",setminus:"\u2216",setmn:"\u2216",sext:"\u2736",Sfr:"\ud835\udd16",sfr:"\ud835\udd30",sfrown:"\u2322",sharp:"\u266f",SHCHcy:"\u0429",shchcy:"\u0449",SHcy:"\u0428",shcy:"\u0448",ShortDownArrow:"\u2193",ShortLeftArrow:"\u2190",shortmid:"\u2223",shortparallel:"\u2225",ShortRightArrow:"\u2192",ShortUpArrow:"\u2191",shy:"\xad",Sigma:"\u03a3",sigma:"\u03c3",sigmaf:"\u03c2",sigmav:"\u03c2",sim:"\u223c",simdot:"\u2a6a",sime:"\u2243",simeq:"\u2243",simg:"\u2a9e",simgE:"\u2aa0",siml:"\u2a9d",simlE:"\u2a9f",simne:"\u2246",simplus:"\u2a24",simrarr:"\u2972",slarr:"\u2190",SmallCircle:"\u2218",smallsetminus:"\u2216",smashp:"\u2a33",smeparsl:"\u29e4",smid:"\u2223",smile:"\u2323",smt:"\u2aaa",smte:"\u2aac",smtes:"\u2aac\ufe00",SOFTcy:"\u042c",softcy:"\u044c",solbar:"\u233f",solb:"\u29c4",sol:"/",Sopf:"\ud835\udd4a",sopf:"\ud835\udd64",spades:"\u2660",spadesuit:"\u2660",spar:"\u2225",sqcap:"\u2293",sqcaps:"\u2293\ufe00",sqcup:"\u2294",sqcups:"\u2294\ufe00",Sqrt:"\u221a",sqsub:"\u228f",sqsube:"\u2291",sqsubset:"\u228f",sqsubseteq:"\u2291",sqsup:"\u2290",sqsupe:"\u2292",sqsupset:"\u2290",sqsupseteq:"\u2292",square:"\u25a1",Square:"\u25a1",SquareIntersection:"\u2293",SquareSubset:"\u228f",SquareSubsetEqual:"\u2291",SquareSuperset:"\u2290",SquareSupersetEqual:"\u2292",SquareUnion:"\u2294",squarf:"\u25aa",squ:"\u25a1",squf:"\u25aa",srarr:"\u2192",Sscr:"\ud835\udcae",sscr:"\ud835\udcc8",ssetmn:"\u2216",ssmile:"\u2323",sstarf:"\u22c6",Star:"\u22c6",star:"\u2606",starf:"\u2605",straightepsilon:"\u03f5",straightphi:"\u03d5",strns:"\xaf",sub:"\u2282",Sub:"\u22d0",subdot:"\u2abd",subE:"\u2ac5",sube:"\u2286",subedot:"\u2ac3",submult:"\u2ac1",subnE:"\u2acb",subne:"\u228a",subplus:"\u2abf",subrarr:"\u2979",subset:"\u2282",Subset:"\u22d0",subseteq:"\u2286",subseteqq:"\u2ac5",SubsetEqual:"\u2286",subsetneq:"\u228a",subsetneqq:"\u2acb",subsim:"\u2ac7",subsub:"\u2ad5",subsup:"\u2ad3",succapprox:"\u2ab8",succ:"\u227b",succcurlyeq:"\u227d",Succeeds:"\u227b",SucceedsEqual:"\u2ab0",SucceedsSlantEqual:"\u227d",SucceedsTilde:"\u227f",succeq:"\u2ab0",succnapprox:"\u2aba",succneqq:"\u2ab6",succnsim:"\u22e9",succsim:"\u227f",SuchThat:"\u220b",sum:"\u2211",Sum:"\u2211",sung:"\u266a",sup1:"\xb9",sup2:"\xb2",sup3:"\xb3",sup:"\u2283",Sup:"\u22d1",supdot:"\u2abe",supdsub:"\u2ad8",supE:"\u2ac6",supe:"\u2287",supedot:"\u2ac4",Superset:"\u2283",SupersetEqual:"\u2287",suphsol:"\u27c9",suphsub:"\u2ad7",suplarr:"\u297b",supmult:"\u2ac2",supnE:"\u2acc",supne:"\u228b",supplus:"\u2ac0",supset:"\u2283",Supset:"\u22d1",supseteq:"\u2287",supseteqq:"\u2ac6",supsetneq:"\u228b",supsetneqq:"\u2acc",supsim:"\u2ac8",supsub:"\u2ad4",supsup:"\u2ad6",swarhk:"\u2926",swarr:"\u2199",swArr:"\u21d9",swarrow:"\u2199",swnwar:"\u292a",szlig:"\xdf",Tab:"\t",target:"\u2316",Tau:"\u03a4",tau:"\u03c4",tbrk:"\u23b4",Tcaron:"\u0164",tcaron:"\u0165",Tcedil:"\u0162",tcedil:"\u0163",Tcy:"\u0422",tcy:"\u0442",tdot:"\u20db",telrec:"\u2315",Tfr:"\ud835\udd17",tfr:"\ud835\udd31",there4:"\u2234",therefore:"\u2234",Therefore:"\u2234",Theta:"\u0398",theta:"\u03b8",thetasym:"\u03d1",thetav:"\u03d1",thickapprox:"\u2248",thicksim:"\u223c",ThickSpace:"\u205f\u200a",ThinSpace:"\u2009",thinsp:"\u2009",thkap:"\u2248",thksim:"\u223c",THORN:"\xde",thorn:"\xfe",tilde:"\u02dc",Tilde:"\u223c",TildeEqual:"\u2243",TildeFullEqual:"\u2245",TildeTilde:"\u2248",timesbar:"\u2a31",timesb:"\u22a0",times:"\xd7",timesd:"\u2a30",tint:"\u222d",toea:"\u2928",topbot:"\u2336",topcir:"\u2af1",top:"\u22a4",Topf:"\ud835\udd4b",topf:"\ud835\udd65",topfork:"\u2ada",tosa:"\u2929",tprime:"\u2034",trade:"\u2122",TRADE:"\u2122",triangle:"\u25b5",triangledown:"\u25bf",triangleleft:"\u25c3",trianglelefteq:"\u22b4",triangleq:"\u225c",triangleright:"\u25b9",trianglerighteq:"\u22b5",tridot:"\u25ec",trie:"\u225c",triminus:"\u2a3a",TripleDot:"\u20db",triplus:"\u2a39",trisb:"\u29cd",tritime:"\u2a3b",trpezium:"\u23e2",Tscr:"\ud835\udcaf",tscr:"\ud835\udcc9",TScy:"\u0426",tscy:"\u0446",TSHcy:"\u040b",tshcy:"\u045b",Tstrok:"\u0166",tstrok:"\u0167",twixt:"\u226c",twoheadleftarrow:"\u219e",twoheadrightarrow:"\u21a0",Uacute:"\xda",uacute:"\xfa",uarr:"\u2191",Uarr:"\u219f",uArr:"\u21d1",Uarrocir:"\u2949",Ubrcy:"\u040e",ubrcy:"\u045e",Ubreve:"\u016c",ubreve:"\u016d",Ucirc:"\xdb",ucirc:"\xfb",Ucy:"\u0423",ucy:"\u0443",udarr:"\u21c5",Udblac:"\u0170",udblac:"\u0171",udhar:"\u296e",ufisht:"\u297e",Ufr:"\ud835\udd18",ufr:"\ud835\udd32",Ugrave:"\xd9",ugrave:"\xf9",uHar:"\u2963",uharl:"\u21bf",uharr:"\u21be",uhblk:"\u2580",ulcorn:"\u231c",ulcorner:"\u231c",ulcrop:"\u230f",ultri:"\u25f8",Umacr:"\u016a",umacr:"\u016b",uml:"\xa8",UnderBar:"_",UnderBrace:"\u23df",UnderBracket:"\u23b5",UnderParenthesis:"\u23dd",Union:"\u22c3",UnionPlus:"\u228e",Uogon:"\u0172",uogon:"\u0173",Uopf:"\ud835\udd4c",uopf:"\ud835\udd66",UpArrowBar:"\u2912",uparrow:"\u2191",UpArrow:"\u2191",Uparrow:"\u21d1",UpArrowDownArrow:"\u21c5",updownarrow:"\u2195",UpDownArrow:"\u2195",Updownarrow:"\u21d5",UpEquilibrium:"\u296e",upharpoonleft:"\u21bf",upharpoonright:"\u21be",uplus:"\u228e",UpperLeftArrow:"\u2196",UpperRightArrow:"\u2197",upsi:"\u03c5",Upsi:"\u03d2",upsih:"\u03d2",Upsilon:"\u03a5",upsilon:"\u03c5",UpTeeArrow:"\u21a5",UpTee:"\u22a5",upuparrows:"\u21c8",urcorn:"\u231d",urcorner:"\u231d",urcrop:"\u230e",Uring:"\u016e",uring:"\u016f",urtri:"\u25f9",Uscr:"\ud835\udcb0",uscr:"\ud835\udcca",utdot:"\u22f0",Utilde:"\u0168",utilde:"\u0169",utri:"\u25b5",utrif:"\u25b4",uuarr:"\u21c8",Uuml:"\xdc",uuml:"\xfc",uwangle:"\u29a7",vangrt:"\u299c",varepsilon:"\u03f5",varkappa:"\u03f0",varnothing:"\u2205",varphi:"\u03d5",varpi:"\u03d6",varpropto:"\u221d",varr:"\u2195",vArr:"\u21d5",varrho:"\u03f1",varsigma:"\u03c2",varsubsetneq:"\u228a\ufe00",varsubsetneqq:"\u2acb\ufe00",varsupsetneq:"\u228b\ufe00",varsupsetneqq:"\u2acc\ufe00",vartheta:"\u03d1",vartriangleleft:"\u22b2",vartriangleright:"\u22b3",vBar:"\u2ae8",Vbar:"\u2aeb",vBarv:"\u2ae9",Vcy:"\u0412",vcy:"\u0432",vdash:"\u22a2",vDash:"\u22a8",Vdash:"\u22a9",VDash:"\u22ab",Vdashl:"\u2ae6",veebar:"\u22bb",vee:"\u2228",Vee:"\u22c1",veeeq:"\u225a",vellip:"\u22ee",verbar:"|",Verbar:"\u2016",vert:"|",Vert:"\u2016",VerticalBar:"\u2223",VerticalLine:"|",VerticalSeparator:"\u2758",VerticalTilde:"\u2240",VeryThinSpace:"\u200a",Vfr:"\ud835\udd19",vfr:"\ud835\udd33",vltri:"\u22b2",vnsub:"\u2282\u20d2",vnsup:"\u2283\u20d2",Vopf:"\ud835\udd4d",vopf:"\ud835\udd67",vprop:"\u221d",vrtri:"\u22b3",Vscr:"\ud835\udcb1",vscr:"\ud835\udccb",vsubnE:"\u2acb\ufe00",vsubne:"\u228a\ufe00",vsupnE:"\u2acc\ufe00",vsupne:"\u228b\ufe00",Vvdash:"\u22aa",vzigzag:"\u299a",Wcirc:"\u0174",wcirc:"\u0175",wedbar:"\u2a5f",wedge:"\u2227",Wedge:"\u22c0",wedgeq:"\u2259",weierp:"\u2118",Wfr:"\ud835\udd1a",wfr:"\ud835\udd34",Wopf:"\ud835\udd4e",wopf:"\ud835\udd68",wp:"\u2118",wr:"\u2240",wreath:"\u2240",Wscr:"\ud835\udcb2",wscr:"\ud835\udccc",xcap:"\u22c2",xcirc:"\u25ef",xcup:"\u22c3",xdtri:"\u25bd",Xfr:"\ud835\udd1b",xfr:"\ud835\udd35",xharr:"\u27f7",xhArr:"\u27fa",Xi:"\u039e",xi:"\u03be",xlarr:"\u27f5",xlArr:"\u27f8",xmap:"\u27fc",xnis:"\u22fb",xodot:"\u2a00",Xopf:"\ud835\udd4f",xopf:"\ud835\udd69",xoplus:"\u2a01",xotime:"\u2a02",xrarr:"\u27f6",xrArr:"\u27f9",Xscr:"\ud835\udcb3",xscr:"\ud835\udccd",xsqcup:"\u2a06",xuplus:"\u2a04",xutri:"\u25b3",xvee:"\u22c1",xwedge:"\u22c0",Yacute:"\xdd",yacute:"\xfd",YAcy:"\u042f",yacy:"\u044f",Ycirc:"\u0176",ycirc:"\u0177",Ycy:"\u042b",ycy:"\u044b",yen:"\xa5",Yfr:"\ud835\udd1c",yfr:"\ud835\udd36",YIcy:"\u0407",yicy:"\u0457",Yopf:"\ud835\udd50",yopf:"\ud835\udd6a",Yscr:"\ud835\udcb4",yscr:"\ud835\udcce",YUcy:"\u042e",yucy:"\u044e",yuml:"\xff",Yuml:"\u0178",Zacute:"\u0179",zacute:"\u017a",Zcaron:"\u017d",zcaron:"\u017e",Zcy:"\u0417",zcy:"\u0437",Zdot:"\u017b",zdot:"\u017c",zeetrf:"\u2128",ZeroWidthSpace:"\u200b",Zeta:"\u0396",zeta:"\u03b6",zfr:"\ud835\udd37",Zfr:"\u2128",ZHcy:"\u0416",zhcy:"\u0436",zigrarr:"\u21dd",zopf:"\ud835\udd6b",Zopf:"\u2124",Zscr:"\ud835\udcb5",zscr:"\ud835\udccf",zwj:"\u200d",zwnj:"\u200c"}},{}],53:[function(e,r,t){"use strict";function n(e){var r=Array.prototype.slice.call(arguments,1);return r.forEach((function(r){r&&Object.keys(r).forEach((function(t){e[t]=r[t]}))})),e}function s(e){return Object.prototype.toString.call(e)}function o(e){return"[object Function]"===s(e)}function i(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}var a={fuzzyLink:!0,fuzzyEmail:!0,fuzzyIP:!1};var c={"http:":{validate:function(e,r,t){var n=e.slice(r);return t.re.http||(t.re.http=new RegExp("^\\/\\/"+t.re.src_auth+t.re.src_host_port_strict+t.re.src_path,"i")),t.re.http.test(n)?n.match(t.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,r,t){var n=e.slice(r);return t.re.no_http||(t.re.no_http=new RegExp("^"+t.re.src_auth+"(?:localhost|(?:(?:"+t.re.src_domain+")\\.)+"+t.re.src_domain_root+")"+t.re.src_port+t.re.src_host_terminator+t.re.src_path,"i")),t.re.no_http.test(n)?r>=3&&":"===e[r-3]||r>=3&&"/"===e[r-3]?0:n.match(t.re.no_http)[0].length:0}},"mailto:":{validate:function(e,r,t){var n=e.slice(r);return t.re.mailto||(t.re.mailto=new RegExp("^"+t.re.src_email_name+"@"+t.re.src_host_strict,"i")),t.re.mailto.test(n)?n.match(t.re.mailto)[0].length:0}}},l="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|\u0440\u0444".split("|");function u(r){var t=r.re=e("./lib/re")(r.__opts__),n=r.__tlds__.slice();function a(e){return e.replace("%TLDS%",t.src_tlds)}r.onCompile(),r.__tlds_replaced__||n.push("a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]"),n.push(t.src_xn),t.src_tlds=n.join("|"),t.email_fuzzy=RegExp(a(t.tpl_email_fuzzy),"i"),t.link_fuzzy=RegExp(a(t.tpl_link_fuzzy),"i"),t.link_no_ip_fuzzy=RegExp(a(t.tpl_link_no_ip_fuzzy),"i"),t.host_fuzzy_test=RegExp(a(t.tpl_host_fuzzy_test),"i");var c=[];function l(e,r){throw new Error('(LinkifyIt) Invalid schema "'+e+'": '+r)}r.__compiled__={},Object.keys(r.__schemas__).forEach((function(e){var t=r.__schemas__[e];if(null!==t){var n={validate:null,link:null};if(r.__compiled__[e]=n,"[object Object]"===s(t))return!function(e){return"[object RegExp]"===s(e)}(t.validate)?o(t.validate)?n.validate=t.validate:l(e,t):n.validate=function(e){return function(r,t){var n=r.slice(t);return e.test(n)?n.match(e)[0].length:0}}(t.validate),void(o(t.normalize)?n.normalize=t.normalize:t.normalize?l(e,t):n.normalize=function(e,r){r.normalize(e)});!function(e){return"[object String]"===s(e)}(t)?l(e,t):c.push(e)}})),c.forEach((function(e){r.__compiled__[r.__schemas__[e]]&&(r.__compiled__[e].validate=r.__compiled__[r.__schemas__[e]].validate,r.__compiled__[e].normalize=r.__compiled__[r.__schemas__[e]].normalize)})),r.__compiled__[""]={validate:null,normalize:function(e,r){r.normalize(e)}};var u=Object.keys(r.__compiled__).filter((function(e){return e.length>0&&r.__compiled__[e]})).map(i).join("|");r.re.schema_test=RegExp("(^|(?!_)(?:[><\uff5c]|"+t.src_ZPCc+"))("+u+")","i"),r.re.schema_search=RegExp("(^|(?!_)(?:[><\uff5c]|"+t.src_ZPCc+"))("+u+")","ig"),r.re.pretest=RegExp("("+r.re.schema_test.source+")|("+r.re.host_fuzzy_test.source+")|@","i"),function(e){e.__index__=-1,e.__text_cache__=""}(r)}function p(e,r){var t=e.__index__,n=e.__last_index__,s=e.__text_cache__.slice(t,n);this.schema=e.__schema__.toLowerCase(),this.index=t+r,this.lastIndex=n+r,this.raw=s,this.text=s,this.url=s}function h(e,r){var t=new p(e,r);return e.__compiled__[t.schema].normalize(t,e),t}function f(e,r){if(!(this instanceof f))return new f(e,r);var t;r||(t=e,Object.keys(t||{}).reduce((function(e,r){return e||a.hasOwnProperty(r)}),!1)&&(r=e,e={})),this.__opts__=n({},a,r),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=n({},c,e),this.__compiled__={},this.__tlds__=l,this.__tlds_replaced__=!1,this.re={},u(this)}f.prototype.add=function(e,r){return this.__schemas__[e]=r,u(this),this},f.prototype.set=function(e){return this.__opts__=n(this.__opts__,e),this},f.prototype.test=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return!1;var r,t,n,s,o,i,a,c;if(this.re.schema_test.test(e))for((a=this.re.schema_search).lastIndex=0;null!==(r=a.exec(e));)if(s=this.testSchemaAt(e,r[2],a.lastIndex)){this.__schema__=r[2],this.__index__=r.index+r[1].length,this.__last_index__=r.index+r[0].length+s;break}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(c=e.search(this.re.host_fuzzy_test))>=0&&(this.__index__<0||c<this.__index__)&&null!==(t=e.match(this.__opts__.fuzzyIP?this.re.link_fuzzy:this.re.link_no_ip_fuzzy))&&(o=t.index+t[1].length,(this.__index__<0||o<this.__index__)&&(this.__schema__="",this.__index__=o,this.__last_index__=t.index+t[0].length)),this.__opts__.fuzzyEmail&&this.__compiled__["mailto:"]&&e.indexOf("@")>=0&&null!==(n=e.match(this.re.email_fuzzy))&&(o=n.index+n[1].length,i=n.index+n[0].length,(this.__index__<0||o<this.__index__||o===this.__index__&&i>this.__last_index__)&&(this.__schema__="mailto:",this.__index__=o,this.__last_index__=i)),this.__index__>=0},f.prototype.pretest=function(e){return this.re.pretest.test(e)},f.prototype.testSchemaAt=function(e,r,t){return this.__compiled__[r.toLowerCase()]?this.__compiled__[r.toLowerCase()].validate(e,t,this):0},f.prototype.match=function(e){var r=0,t=[];this.__index__>=0&&this.__text_cache__===e&&(t.push(h(this,r)),r=this.__last_index__);for(var n=r?e.slice(r):e;this.test(n);)t.push(h(this,r)),n=n.slice(this.__last_index__),r+=this.__last_index__;return t.length?t:null},f.prototype.tlds=function(e,r){return e=Array.isArray(e)?e:[e],r?(this.__tlds__=this.__tlds__.concat(e).sort().filter((function(e,r,t){return e!==t[r-1]})).reverse(),u(this),this):(this.__tlds__=e.slice(),this.__tlds_replaced__=!0,u(this),this)},f.prototype.normalize=function(e){e.schema||(e.url="http://"+e.url),"mailto:"!==e.schema||/^mailto:/i.test(e.url)||(e.url="mailto:"+e.url)},f.prototype.onCompile=function(){},r.exports=f},{"./lib/re":54}],54:[function(e,r,t){"use strict";r.exports=function(r){var t={};t.src_Any=e("uc.micro/properties/Any/regex").source,t.src_Cc=e("uc.micro/categories/Cc/regex").source,t.src_Z=e("uc.micro/categories/Z/regex").source,t.src_P=e("uc.micro/categories/P/regex").source,t.src_ZPCc=[t.src_Z,t.src_P,t.src_Cc].join("|"),t.src_ZCc=[t.src_Z,t.src_Cc].join("|");return t.src_pseudo_letter="(?:(?![><\uff5c]|"+t.src_ZPCc+")"+t.src_Any+")",t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",t.src_auth="(?:(?:(?!"+t.src_ZCc+"|[@/\\[\\]()]).)+@)?",t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",t.src_host_terminator="(?=$|[><\uff5c]|"+t.src_ZPCc+")(?!-|_|:\\d|\\.-|\\.(?!$|"+t.src_ZPCc+"))",t.src_path="(?:[/?#](?:(?!"+t.src_ZCc+"|[><\uff5c]|[()[\\]{}.,\"'?!\\-]).|\\[(?:(?!"+t.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+t.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+t.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+t.src_ZCc+'|["]).)+\\"|\\\'(?:(?!'+t.src_ZCc+"|[']).)+\\'|\\'(?="+t.src_pseudo_letter+"|[-]).|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!"+t.src_ZCc+"|[.]).|"+(r&&r["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+"\\,(?!"+t.src_ZCc+").|\\!(?!"+t.src_ZCc+").|\\?(?!"+t.src_ZCc+"|[?]).)+|\\/)?",t.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',t.src_xn="xn--[a-z0-9\\-]{1,59}",t.src_domain_root="(?:"+t.src_xn+"|"+t.src_pseudo_letter+"{1,63})",t.src_domain="(?:"+t.src_xn+"|(?:"+t.src_pseudo_letter+")|(?:"+t.src_pseudo_letter+"(?:-|"+t.src_pseudo_letter+"){0,61}"+t.src_pseudo_letter+"))",t.src_host="(?:(?:(?:(?:"+t.src_domain+")\\.)*"+t.src_domain+"))",t.tpl_host_fuzzy="(?:"+t.src_ip4+"|(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%)))",t.tpl_host_no_ip_fuzzy="(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%))",t.src_host_strict=t.src_host+t.src_host_terminator,t.tpl_host_fuzzy_strict=t.tpl_host_fuzzy+t.src_host_terminator,t.src_host_port_strict=t.src_host+t.src_port+t.src_host_terminator,t.tpl_host_port_fuzzy_strict=t.tpl_host_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_port_no_ip_fuzzy_strict=t.tpl_host_no_ip_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+t.src_ZPCc+"|>|$))",t.tpl_email_fuzzy='(^|[><\uff5c]|"|\\(|'+t.src_ZCc+")("+t.src_email_name+"@"+t.tpl_host_fuzzy_strict+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|\uff5c]|"+t.src_ZPCc+"))((?![$+<=>^`|\uff5c])"+t.tpl_host_port_fuzzy_strict+t.src_path+")",t.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|\uff5c]|"+t.src_ZPCc+"))((?![$+<=>^`|\uff5c])"+t.tpl_host_port_no_ip_fuzzy_strict+t.src_path+")",t}},{"uc.micro/categories/Cc/regex":61,"uc.micro/categories/P/regex":63,"uc.micro/categories/Z/regex":64,"uc.micro/properties/Any/regex":66}],55:[function(e,r,t){"use strict";var n={};function s(e,r){var t;return"string"!=typeof r&&(r=s.defaultChars),t=function(e){var r,t,s=n[e];if(s)return s;for(s=n[e]=[],r=0;r<128;r++)t=String.fromCharCode(r),s.push(t);for(r=0;r<e.length;r++)s[t=e.charCodeAt(r)]="%"+("0"+t.toString(16).toUpperCase()).slice(-2);return s}(r),e.replace(/(%[a-f0-9]{2})+/gi,(function(e){var r,n,s,o,i,a,c,l="";for(r=0,n=e.length;r<n;r+=3)(s=parseInt(e.slice(r+1,r+3),16))<128?l+=t[s]:192==(224&s)&&r+3<n&&128==(192&(o=parseInt(e.slice(r+4,r+6),16)))?(l+=(c=s<<6&1984|63&o)<128?"\ufffd\ufffd":String.fromCharCode(c),r+=3):224==(240&s)&&r+6<n&&(o=parseInt(e.slice(r+4,r+6),16),i=parseInt(e.slice(r+7,r+9),16),128==(192&o)&&128==(192&i))?(l+=(c=s<<12&61440|o<<6&4032|63&i)<2048||c>=55296&&c<=57343?"\ufffd\ufffd\ufffd":String.fromCharCode(c),r+=6):240==(248&s)&&r+9<n&&(o=parseInt(e.slice(r+4,r+6),16),i=parseInt(e.slice(r+7,r+9),16),a=parseInt(e.slice(r+10,r+12),16),128==(192&o)&&128==(192&i)&&128==(192&a))?((c=s<<18&1835008|o<<12&258048|i<<6&4032|63&a)<65536||c>1114111?l+="\ufffd\ufffd\ufffd\ufffd":(c-=65536,l+=String.fromCharCode(55296+(c>>10),56320+(1023&c))),r+=9):l+="\ufffd";return l}))}s.defaultChars=";/?:@&=+$,#",s.componentChars="",r.exports=s},{}],56:[function(e,r,t){"use strict";var n={};function s(e,r,t){var o,i,a,c,l,u="";for("string"!=typeof r&&(t=r,r=s.defaultChars),void 0===t&&(t=!0),l=function(e){var r,t,s=n[e];if(s)return s;for(s=n[e]=[],r=0;r<128;r++)t=String.fromCharCode(r),/^[0-9a-z]$/i.test(t)?s.push(t):s.push("%"+("0"+r.toString(16).toUpperCase()).slice(-2));for(r=0;r<e.length;r++)s[e.charCodeAt(r)]=e[r];return s}(r),o=0,i=e.length;o<i;o++)if(a=e.charCodeAt(o),t&&37===a&&o+2<i&&/^[0-9a-f]{2}$/i.test(e.slice(o+1,o+3)))u+=e.slice(o,o+3),o+=2;else if(a<128)u+=l[a];else if(a>=55296&&a<=57343){if(a>=55296&&a<=56319&&o+1<i&&(c=e.charCodeAt(o+1))>=56320&&c<=57343){u+=encodeURIComponent(e[o]+e[o+1]),o++;continue}u+="%EF%BF%BD"}else u+=encodeURIComponent(e[o]);return u}s.defaultChars=";/?:@&=+$,-_.!~*'()#",s.componentChars="-_.!~*'()",r.exports=s},{}],57:[function(e,r,t){"use strict";r.exports=function(e){var r="";return r+=e.protocol||"",r+=e.slashes?"//":"",r+=e.auth?e.auth+"@":"",e.hostname&&-1!==e.hostname.indexOf(":")?r+="["+e.hostname+"]":r+=e.hostname||"",r+=e.port?":"+e.port:"",r+=e.pathname||"",r+=e.search||"",r+=e.hash||""}},{}],58:[function(e,r,t){"use strict";r.exports.encode=e("./encode"),r.exports.decode=e("./decode"),r.exports.format=e("./format"),r.exports.parse=e("./parse")},{"./decode":55,"./encode":56,"./format":57,"./parse":59}],59:[function(e,r,t){"use strict";function n(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}var s=/^([a-z0-9.+-]+:)/i,o=/:[0-9]*$/,i=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,a=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),c=["'"].concat(a),l=["%","/","?",";","#"].concat(c),u=["/","?","#"],p=/^[+a-z0-9A-Z_-]{0,63}$/,h=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,f={javascript:!0,"javascript:":!0},d={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};n.prototype.parse=function(e,r){var t,n,o,a,c,m=e;if(m=m.trim(),!r&&1===e.split("#").length){var _=i.exec(m);if(_)return this.pathname=_[1],_[2]&&(this.search=_[2]),this}var g=s.exec(m);if(g&&(o=(g=g[0]).toLowerCase(),this.protocol=g,m=m.substr(g.length)),(r||g||m.match(/^\/\/[^@\/]+@[^@\/]+/))&&(!(c="//"===m.substr(0,2))||g&&f[g]||(m=m.substr(2),this.slashes=!0)),!f[g]&&(c||g&&!d[g])){var k,b,v=-1;for(t=0;t<u.length;t++)-1!==(a=m.indexOf(u[t]))&&(-1===v||a<v)&&(v=a);for(-1!==(b=-1===v?m.lastIndexOf("@"):m.lastIndexOf("@",v))&&(k=m.slice(0,b),m=m.slice(b+1),this.auth=k),v=-1,t=0;t<l.length;t++)-1!==(a=m.indexOf(l[t]))&&(-1===v||a<v)&&(v=a);-1===v&&(v=m.length),":"===m[v-1]&&v--;var y=m.slice(0,v);m=m.slice(v),this.parseHost(y),this.hostname=this.hostname||"";var C="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!C){var x=this.hostname.split(/\./);for(t=0,n=x.length;t<n;t++){var A=x[t];if(A&&!A.match(p)){for(var w="",D=0,E=A.length;D<E;D++)A.charCodeAt(D)>127?w+="x":w+=A[D];if(!w.match(p)){var q=x.slice(0,t),F=x.slice(t+1),S=A.match(h);S&&(q.push(S[1]),F.unshift(S[2])),F.length&&(m=F.join(".")+m),this.hostname=q.join(".");break}}}}this.hostname.length>255&&(this.hostname=""),C&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}var L=m.indexOf("#");-1!==L&&(this.hash=m.substr(L),m=m.slice(0,L));var z=m.indexOf("?");return-1!==z&&(this.search=m.substr(z),m=m.slice(0,z)),m&&(this.pathname=m),d[o]&&this.hostname&&!this.pathname&&(this.pathname=""),this},n.prototype.parseHost=function(e){var r=o.exec(e);r&&(":"!==(r=r[0])&&(this.port=r.substr(1)),e=e.substr(0,e.length-r.length)),e&&(this.hostname=e)},r.exports=function(e,r){if(e&&e instanceof n)return e;var t=new n;return t.parse(e,r),t}},{}],60:[function(e,r,t){(function(e){!function(n){var s="object"==typeof t&&t&&!t.nodeType&&t,o="object"==typeof r&&r&&!r.nodeType&&r,i="object"==typeof e&&e;i.global!==i&&i.window!==i&&i.self!==i||(n=i);var a,c,l=2147483647,u=/^xn--/,p=/[^\x20-\x7E]/,h=/[\x2E\u3002\uFF0E\uFF61]/g,f={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},d=Math.floor,m=String.fromCharCode;function _(e){throw new RangeError(f[e])}function g(e,r){for(var t=e.length,n=[];t--;)n[t]=r(e[t]);return n}function k(e,r){var t=e.split("@"),n="";return t.length>1&&(n=t[0]+"@",e=t[1]),n+g((e=e.replace(h,".")).split("."),r).join(".")}function b(e){for(var r,t,n=[],s=0,o=e.length;s<o;)(r=e.charCodeAt(s++))>=55296&&r<=56319&&s<o?56320==(64512&(t=e.charCodeAt(s++)))?n.push(((1023&r)<<10)+(1023&t)+65536):(n.push(r),s--):n.push(r);return n}function v(e){return g(e,(function(e){var r="";return e>65535&&(r+=m((e-=65536)>>>10&1023|55296),e=56320|1023&e),r+=m(e)})).join("")}function y(e,r){return e+22+75*(e<26)-((0!=r)<<5)}function C(e,r,t){var n=0;for(e=t?d(e/700):e>>1,e+=d(e/r);e>455;n+=36)e=d(e/35);return d(n+36*e/(e+38))}function x(e){var r,t,n,s,o,i,a,c,u,p,h,f=[],m=e.length,g=0,k=128,b=72;for((t=e.lastIndexOf("-"))<0&&(t=0),n=0;n<t;++n)e.charCodeAt(n)>=128&&_("not-basic"),f.push(e.charCodeAt(n));for(s=t>0?t+1:0;s<m;){for(o=g,i=1,a=36;s>=m&&_("invalid-input"),((c=(h=e.charCodeAt(s++))-48<10?h-22:h-65<26?h-65:h-97<26?h-97:36)>=36||c>d((l-g)/i))&&_("overflow"),g+=c*i,!(c<(u=a<=b?1:a>=b+26?26:a-b));a+=36)i>d(l/(p=36-u))&&_("overflow"),i*=p;b=C(g-o,r=f.length+1,0==o),d(g/r)>l-k&&_("overflow"),k+=d(g/r),g%=r,f.splice(g++,0,k)}return v(f)}function A(e){var r,t,n,s,o,i,a,c,u,p,h,f,g,k,v,x=[];for(f=(e=b(e)).length,r=128,t=0,o=72,i=0;i<f;++i)(h=e[i])<128&&x.push(m(h));for(n=s=x.length,s&&x.push("-");n<f;){for(a=l,i=0;i<f;++i)(h=e[i])>=r&&h<a&&(a=h);for(a-r>d((l-t)/(g=n+1))&&_("overflow"),t+=(a-r)*g,r=a,i=0;i<f;++i)if((h=e[i])<r&&++t>l&&_("overflow"),h==r){for(c=t,u=36;!(c<(p=u<=o?1:u>=o+26?26:u-o));u+=36)v=c-p,k=36-p,x.push(m(y(p+v%k,0))),c=d(v/k);x.push(m(y(c,0))),o=C(t,g,n==s),t=0,++n}++t,++r}return x.join("")}if(a={version:"1.4.1",ucs2:{decode:b,encode:v},decode:x,encode:A,toASCII:function(e){return k(e,(function(e){return p.test(e)?"xn--"+A(e):e}))},toUnicode:function(e){return k(e,(function(e){return u.test(e)?x(e.slice(4).toLowerCase()):e}))}},s&&o)if(r.exports==s)o.exports=a;else for(c in a)a.hasOwnProperty(c)&&(s[c]=a[c]);else n.punycode=a}(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],61:[function(e,r,t){r.exports=/[\0-\x1F\x7F-\x9F]/},{}],62:[function(e,r,t){r.exports=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/},{}],63:[function(e,r,t){r.exports=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4E\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDF55-\uDF59]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDF3C-\uDF3E]|\uD806[\uDC3B\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/},{}],64:[function(e,r,t){r.exports=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/},{}],65:[function(e,r,t){"use strict";t.Any=e("./properties/Any/regex"),t.Cc=e("./categories/Cc/regex"),t.Cf=e("./categories/Cf/regex"),t.P=e("./categories/P/regex"),t.Z=e("./categories/Z/regex")},{"./categories/Cc/regex":61,"./categories/Cf/regex":62,"./categories/P/regex":63,"./categories/Z/regex":64,"./properties/Any/regex":66}],66:[function(e,r,t){r.exports=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/},{}],67:[function(e,r,t){"use strict";r.exports=e("./lib/")},{"./lib/":9}]},{},[67])(67)})); +</script> + <script> + var target = document.getElementById('overview-content'); + var md = window.markdownit({ + html: true, + }); + target.innerHTML = md.render(atob('IyMgVGVzdCBTdW1tYXJ5Cgo8ZGl2IGNsYXNzPSJwcm9ncmVzcyI+CiAgPGRpdiBjbGFzcz0icHJvZ3Jlc3MtYmFyIHByb2dyZXNzLWJhci1zdWNjZXNzIiBzdHlsZT0id2lkdGg6IDEwMC4wJSIgYXJpYS12YWx1ZW5vdz0iMSIgYXJpYS12YWx1ZW1pbj0iMCIgYXJpYS12YWx1ZW1heD0iMSIgZGF0YS10b2dnbGU9InRvb2x0aXAiIHRpdGxlPSIxIFBhc3NlZCI+CiAgPC9kaXY+CiAgPGRpdiBjbGFzcz0icHJvZ3Jlc3MtYmFyIHByb2dyZXNzLWJhci13YXJuaW5nIiBzdHlsZT0id2lkdGg6IDAuMCUiIGFyaWEtdmFsdWVub3c9IjAiIGFyaWEtdmFsdWVtaW49IjAiIGFyaWEtdmFsdWVtYXg9IjEiIGRhdGEtdG9nZ2xlPSJ0b29sdGlwIiB0aXRsZT0iMCBTa2lwcGVkIj4KICA8L2Rpdj4KICA8ZGl2IGNsYXNzPSJwcm9ncmVzcy1iYXIgcHJvZ3Jlc3MtYmFyLWRhbmdlciIgc3R5bGU9IndpZHRoOiAwLjAlIiBhcmlhLXZhbHVlbm93PSIwIiBhcmlhLXZhbHVlbWluPSIwIiBhcmlhLXZhbHVlbWF4PSIxIiB0aXRsZT0iMCBGYWlsZWQgb3IgRXJyb3JlZCI+CiAgPC9kaXY+CjwvZGl2PgoKfCBUZXN0IFN0YXRlIHwgQ291bnQgfAp8IC0tLS0tLS0tLS0gfCAtLS0tLSB8CnwgVG90YWwgICAgICB8IDEgfAp8IFBhc3NlZCAgICAgfCAxIHwKfCBFcnJvciAgICAgIHwgMCB8CnwgRmFpbHVyZSAgICB8IDAgfAp8IFNraXBwZWQgICAgfCAwIHwKCgo8ZGV0YWlscz48c3VtbWFyeT5QYXNzZWQgVGVzdHM8L3N1bW1hcnk+CgoqIDxkZXRhaWxzIGNsYXNzPSJyY29ybmVycyBsaWdodC1ncmVlbiI+PHN1bW1hcnkgY2xhc3M9ImxpZ2h0LWdyZWVuIj4mIzk5ODk7IHRhY3JldiAoVGVzdCAjMSk8L3N1bW1hcnk+PGRpdiBjbGFzcz0icGFkZGVkIj4KCiAgICAqKkNvbW1hbmQgTGluZToqKgoKICAgICogYGBgY29uc29sZQogICAgICBiYXNoIC93b3JrL2dhbGF4eXRmL2RhdGFiYXNlL3RtcC90bXBseF8zcXJtay9qb2Jfd29ya2luZ19kaXJlY3RvcnkvMDAwLzIvY29uZmlncy90bXBqdjBmbzFnaSA8IC93b3JrL2dhbGF4eXRmL2RhdGFiYXNlL3RtcC90bXBseF8zcXJtay9maWxlcy9mL2QvZi9kYXRhc2V0X2ZkZmE1YzI2LTEzMTYtNDc3MC04NzZiLWZjZDJjOTMxMjIxNy5kYXQgPiAvd29yay9nYWxheHl0Zi9kYXRhYmFzZS90bXAvdG1wbHhfM3FybWsvam9iX3dvcmtpbmdfZGlyZWN0b3J5LzAwMC8yL291dHB1dHMvZ2FsYXh5X2RhdGFzZXRfZjdkN2UxMWMtMTkwMy00YWNhLWJhMTEtYjQ0MmYwNDk3MTdkLmRhdAogICAgICBgYGAKICAgICoqRXhpdCBDb2RlOioqCgogICAgKiBgYGBjb25zb2xlCiAgICAgIDAKICAgICAgYGBgCiAgICoqSm9iIFBhcmFtZXRlcnM6KioKCiAgICogICB8IEpvYiBwYXJhbWV0ZXIgfCBQYXJhbWV0ZXIgdmFsdWUgfAogICAgICAgfCAtLS0tLS0tLS0tLS0tIHwgLS0tLS0tLS0tLS0tLS0tIHwKICAgICAgIHwgY2hyb21JbmZvIHwgYCAiL3dvcmsvZ2FsYXh5dGYvdG9vbC1kYXRhL3NoYXJlZC91Y3NjL2Nocm9tLz8ubGVuIiBgIHwKICAgICAgIHwgZGJrZXkgfCBgICI/IiBgIHwKICAgICAgIHwgXF9cX2lucHV0XF9leHQgfCBgICJ0eHQiIGAgfAoKCgogIDwvZGl2PjwvZGV0YWlscz4KCgo8L2RldGFpbHM+Cg==')); + </script> + </body> +</html> \ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/plants.sh Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1 @@ +planemo shed_update --shed_target toolshed --owner fubar --name mashmap --shed_key bbfaa3d1d522066d41a4250dc419cc6f ./
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/pyrev_pos_test/pyrev_pos_test.python.txt Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,17 @@ +#raw +## reverse order of text by row +## ToolFactory demonstration +## positional parameters +import sys +inp = sys.argv[1] +outp = sys.argv[2] +i = open(inp,'r').readlines() +o = open(outp,'w') +for row in i: + rs = row.rstrip() + rs = list(rs) + rs.reverse() + o.write(''.join(rs)) + o.write('\n') +o.close() +#end raw
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/pyrev_pos_test/pyrev_pos_test.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,49 @@ +<tool name="pyrev_pos_test" id="pyrev_pos_test" version="0.01" profile="22.05"> + <!--Source in git at: https://github.com/fubar2/galaxy_tf_overlay--> + <!--Created by toolfactory@galaxy.org at 22/02/2024 10:27:18 using the Galaxy Tool Factory.--> + <description></description> + <requirements/> + <version_command><![CDATA[echo "0.01"]]></version_command> + <command><![CDATA[python +'$runme' +$Input_text_file_to_be_reversed +$pyrev_positionalparse_output]]></command> + <configfiles> + <configfile name="runme"><![CDATA[#raw +## reverse order of text by row +## ToolFactory demonstration +## positional parameters +import sys +inp = sys.argv[1] +outp = sys.argv[2] +i = open(inp,'r').readlines() +o = open(outp,'w') +for row in i: + rs = row.rstrip() + rs = list(rs) + rs.reverse() + o.write(''.join(rs)) + o.write('\n') +o.close() +#end raw]]></configfile> + </configfiles> + <inputs> + <param name="Input_text_file_to_be_reversed" type="data" optional="false" label="Input text file to be reversed" help="" format="txt" multiple="false"/> + </inputs> + <outputs> + <data name="pyrev_positionalparse_output" format="txt" label="pyrev_positionalparse_output" hidden="false"/> + </outputs> + <tests> + <test> + <output name="pyrev_positionalparse_output" value="pyrev_positionalparse_output_sample" compare="diff" lines_diff="0"/> + <param name="Input_text_file_to_be_reversed" value="Input_text_file_to_be_reversed_sample"/> + </test> + </tests> + <help><![CDATA[ + **What it Does** + ]]></help> + <citations> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/pyrev_pos_test/test-data/Input_text_file_to_be_reversed_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1210 @@ +# see https://github.com/fubar2/toolfactory +# +# copyright ross lazarus (ross stop lazarus at gmail stop com) May 2012 +# +# all rights reserved +# Licensed under the LGPL +# suggestions for improvement and bug fixes welcome at +# https://github.com/fubar2/toolfactory +# +# march 2022: Refactored into two tools - generate and test/install +# as part of GTN tutorial development and biocontainer adoption +# The tester runs planemo on a non-tested archive, creates the test outputs +# and returns a new proper tool with test. + + + +import argparse +import copy +import fcntl +import json +import os +import re +import shlex +import shutil +import subprocess +import sys +import tarfile +import tempfile +import time + +from bioblend import galaxy + +import galaxyxml.tool as gxt +import galaxyxml.tool.parameters as gxtp + +import lxml.etree as ET + +import yaml + +myversion = "V2.4 March 2022" +verbose = True +debug = True +toolFactoryURL = "https://github.com/fubar2/toolfactory" +FAKEEXE = "~~~REMOVE~~~ME~~~" +# need this until a PR/version bump to fix galaxyxml prepending the exe even +# with override. + + +def timenow(): + """return current time as a string""" + return time.strftime("%d/%m/%Y %H:%M:%S", time.localtime(time.time())) + + +cheetah_escape_table = {"$": "\\$", "#": "\\#"} + + +def cheetah_escape(text): + """Produce entities within text.""" + return "".join([cheetah_escape_table.get(c, c) for c in text]) + + +def parse_citations(citations_text): + """""" + citations = [c for c in citations_text.split("**ENTRY**") if c.strip()] + citation_tuples = [] + for citation in citations: + if citation.startswith("doi"): + citation_tuples.append(("doi", citation[len("doi") :].strip())) + else: + citation_tuples.append(("bibtex", citation[len("bibtex") :].strip())) + return citation_tuples + + +class Tool_Factory: + """Wrapper for an arbitrary script + uses galaxyxml + + """ + + def __init__(self, args=None): # noqa + """ + prepare command line cl for running the tool here + and prepare elements needed for galaxyxml tool generation + """ + self.local_tools = os.path.join(args.galaxy_root,'local_tools') + self.ourcwd = os.getcwd() + self.collections = [] + if len(args.collection) > 0: + try: + self.collections = [ + json.loads(x) for x in args.collection if len(x.strip()) > 1 + ] + except Exception: + print( + f"--collections parameter {str(args.collection)} is malformed - should be a dictionary" + ) + try: + self.infiles = [ + json.loads(x) for x in args.input_files if len(x.strip()) > 1 + ] + except Exception: + print( + f"--input_files parameter {str(args.input_files)} is malformed - should be a dictionary" + ) + try: + self.outfiles = [ + json.loads(x) for x in args.output_files if len(x.strip()) > 1 + ] + except Exception: + print( + f"--output_files parameter {args.output_files} is malformed - should be a dictionary" + ) + assert (len(self.outfiles) + len(self.collections)) > 0, 'No outfiles or output collections specified. The Galaxy job runner will fail without an output of some sort' + try: + self.addpar = [ + json.loads(x) for x in args.additional_parameters if len(x.strip()) > 1 + ] + except Exception: + print( + f"--additional_parameters {args.additional_parameters} is malformed - should be a dictionary" + ) + try: + self.selpar = [ + json.loads(x) for x in args.selecttext_parameters if len(x.strip()) > 1 + ] + except Exception: + print( + f"--selecttext_parameters {args.selecttext_parameters} is malformed - should be a dictionary" + ) + self.args = args + self.cleanuppar() + self.lastxclredirect = None + self.xmlcl = [] + self.is_positional = self.args.parampass == "positional" + if self.args.sysexe: + if " " in self.args.sysexe: + self.executeme = shlex.split(self.args.sysexe) + else: + self.executeme = [ + self.args.sysexe, + ] + else: + if self.args.packages: + self.executeme = [ + self.args.packages.split(",")[0].split(":")[0].strip(), + ] + else: + self.executeme = None + aXCL = self.xmlcl.append + assert args.parampass in [ + "0", + "argparse", + "positional", + ], 'args.parampass must be "0","positional" or "argparse"' + self.tool_name = re.sub("[^a-zA-Z0-9_]+", "", args.tool_name) + self.tool_id = self.tool_name + self.newtool = gxt.Tool( + self.tool_name, + self.tool_id, + self.args.tool_version, + self.args.tool_desc, + FAKEEXE, + ) + self.tooloutdir = "./tfout" + self.repdir = "./toolgen" + self.newtarpath = args.untested_tool_out # os.path.join(self.tooloutdir, "%s_not_tested_toolshed.gz" % self.tool_name) + self.testdir = os.path.join(self.tooloutdir, "test-data") + if not os.path.exists(self.tooloutdir): + os.mkdir(self.tooloutdir) + if not os.path.exists(self.testdir): + os.mkdir(self.testdir) + if not os.path.exists(self.repdir): + os.mkdir(self.repdir) + self.tlog = os.path.join(self.repdir,'%s_TF_run_log.txt' % self.tool_name) + self.tinputs = gxtp.Inputs() + self.toutputs = gxtp.Outputs() + self.testparam = [] + if self.args.script_path: + self.prepScript() + if self.args.command_override: + scos = open(self.args.command_override, "r").readlines() + self.command_override = [x.rstrip() for x in scos] + else: + self.command_override = None + if self.args.test_override: + stos = open(self.args.test_override, "r").readlines() + self.test_override = [x.rstrip() for x in stos] + else: + self.test_override = None + if self.args.script_path: + for ex in self.executeme: + aXCL(ex) + aXCL("$runme") + else: + for ex in self.executeme: + aXCL(ex) + + if self.args.parampass == "0": + self.clsimple() + else: + if self.args.parampass == "positional": + self.prepclpos() + self.clpositional() + else: + self.prepargp() + self.clargparse() + + def clsimple(self): + """no parameters or repeats - uses < and > for i/o""" + aXCL = self.xmlcl.append + if len(self.infiles) > 0: + aXCL("<") + aXCL("$%s" % self.infiles[0]["infilename"]) + if len(self.outfiles) > 0: + aXCL(">") + aXCL("$%s" % self.outfiles[0]["name"]) + if self.args.cl_user_suffix: # DIY CL end + clp = shlex.split(self.args.cl_user_suffix) + for c in clp: + aXCL(c) + + def prepargp(self): + xclsuffix = [] + for i, p in enumerate(self.infiles): + nam = p["infilename"] + if p["origCL"].strip().upper() == "STDIN": + xappendme = [ + nam, + nam, + "< $%s" % nam, + ] + else: + rep = p["repeat"] == "1" + over = "" + if rep: + over = f'#for $rep in $R_{nam}:\n--{nam} "$rep.{nam}"\n#end for' + xappendme = [p["CL"], "$%s" % p["CL"], over] + xclsuffix.append(xappendme) + for i, p in enumerate(self.outfiles): + if p["origCL"].strip().upper() == "STDOUT": + self.lastxclredirect = [">", "$%s" % p["name"]] + else: + xclsuffix.append([p["name"], "$%s" % p["name"], ""]) + for p in self.addpar: + nam = p["name"] + rep = p["repeat"] == "1" + if rep: + over = f'#for $rep in $R_{nam}:\n--{nam} "$rep.{nam}"\n#end for' + else: + over = p["override"] + xclsuffix.append([p["CL"], '"$%s"' % nam, over]) + for p in self.selpar: + xclsuffix.append([p["CL"], '"$%s"' % p["name"], p["override"]]) + self.xclsuffix = xclsuffix + + def prepclpos(self): + xclsuffix = [] + for i, p in enumerate(self.infiles): + if p["origCL"].strip().upper() == "STDIN": + xappendme = [ + "999", + p["infilename"], + "< $%s" % p["infilename"], + ] + else: + xappendme = [p["CL"], "$%s" % p["infilename"], ""] + xclsuffix.append(xappendme) + for i, p in enumerate(self.outfiles): + if p["origCL"].strip().upper() == "STDOUT": + self.lastxclredirect = [">", "$%s" % p["name"]] + else: + xclsuffix.append([p["CL"], "$%s" % p["name"], ""]) + for p in self.addpar: + nam = p["name"] + rep = p["repeat"] == "1" # repeats make NO sense + if rep: + print( + f"### warning. Repeats for {nam} ignored - not permitted in positional parameter command lines!" + ) + over = p["override"] + xclsuffix.append([p["CL"], '"$%s"' % nam, over]) + for p in self.selpar: + xclsuffix.append([p["CL"], '"$%s"' % p["name"], p["override"]]) + xclsuffix.sort() + self.xclsuffix = xclsuffix + + def prepScript(self): + rx = open(self.args.script_path, "r").readlines() + rx = [x.rstrip() for x in rx] + rxcheck = [x.strip() for x in rx if x.strip() > ""] + assert len(rxcheck) > 0, "Supplied script is empty. Cannot run" + self.script = "\n".join(rx) + fhandle, self.sfile = tempfile.mkstemp( + prefix=self.tool_name, suffix="_%s" % (self.executeme[0]) + ) + tscript = open(self.sfile, "w") + tscript.write(self.script) + tscript.close() + self.spacedScript = [f" {x}" for x in rx if x.strip() > ""] + rx.insert(0, "#raw") + rx.append("#end raw") + self.escapedScript = rx + art = "%s.%s" % (self.tool_name, self.executeme[0]) + artifact = open(art, "wb") + artifact.write(bytes(self.script, "utf8")) + artifact.close() + + def cleanuppar(self): + """ positional parameters are complicated by their numeric ordinal""" + if self.args.parampass == "positional": + for i, p in enumerate(self.infiles): + assert ( + p["CL"].isdigit() or p["CL"].strip().upper() == "STDIN" + ), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["label"], + ) + for i, p in enumerate(self.outfiles): + assert ( + p["CL"].isdigit() or p["CL"].strip().upper() == "STDOUT" + ), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["name"], + ) + for i, p in enumerate(self.addpar): + assert p[ + "CL" + ].isdigit(), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["name"], + ) + for i, p in enumerate(self.infiles): + infp = copy.copy(p) + infp["origCL"] = infp["CL"] + if self.args.parampass in ["positional", "0"]: + infp["infilename"] = infp["label"].replace(" ", "_") + else: + infp["infilename"] = infp["CL"] + self.infiles[i] = infp + for i, p in enumerate(self.outfiles): + outfp = copy.copy(p) + outfp["origCL"] = outfp["CL"] # keep copy + self.outfiles[i] = outfp + for i, p in enumerate(self.addpar): + addp = copy.copy(p) + addp["origCL"] = addp["CL"] + self.addpar[i] = addp + + def clpositional(self): + # inputs in order then params + aXCL = self.xmlcl.append + for (k, v, koverride) in self.xclsuffix: + aXCL(v) + if self.lastxclredirect: + for cl in self.lastxclredirect: + aXCL(cl) + if self.args.cl_user_suffix: # DIY CL end + clp = shlex.split(self.args.cl_user_suffix) + for c in clp: + aXCL(c) + + def clargparse(self): + """argparse style""" + aXCL = self.xmlcl.append + # inputs then params in argparse named form + + for (k, v, koverride) in self.xclsuffix: + if koverride > "": + k = koverride + aXCL(k) + else: + if len(k.strip()) == 1: + k = "-%s" % k + else: + k = "--%s" % k + aXCL(k) + aXCL(v) + if self.lastxclredirect: + for cl in self.lastxclredirect: + aXCL(cl) + if self.args.cl_user_suffix: # DIY CL end + clp = shlex.split(self.args.cl_user_suffix) + for c in clp: + aXCL(c) + + def getNdash(self, newname): + if self.is_positional: + ndash = 0 + else: + ndash = 2 + if len(newname) < 2: + ndash = 1 + return ndash + + def doXMLparam(self): # noqa + """Add all needed elements to tool""" + for p in self.outfiles: + newname = p["name"] + newfmt = p["format"] + newcl = p["CL"] + test = p["test"] + oldcl = p["origCL"] + test = test.strip() + ndash = self.getNdash(newcl) + aparm = gxtp.OutputData( + name=newname, format=newfmt, num_dashes=ndash, label=newname + ) + aparm.positional = self.is_positional + if self.is_positional: + if oldcl.upper() == "STDOUT": + aparm.positional = 9999999 + aparm.command_line_override = "> $%s" % newname + else: + aparm.positional = int(oldcl) + aparm.command_line_override = "$%s" % newname + self.toutputs.append(aparm) + ld = None + if test.strip() > "": + if test.strip().startswith("diff"): + c = "diff" + ld = 0 + if test.split(":")[1].isdigit: + ld = int(test.split(":")[1]) + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + lines_diff=ld, + ) + elif test.startswith("sim_size"): + c = "sim_size" + tn = test.split(":")[1].strip() + if tn > "": + if "." in tn: + delta = None + delta_frac = min(1.0, float(tn)) + else: + delta = int(tn) + delta_frac = None + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + delta=delta, + delta_frac=delta_frac, + ) + else: + c = test + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + ) + self.testparam.append(tp) + for p in self.infiles: + newname = p["infilename"] + newfmt = p["format"] + ndash = self.getNdash(newname) + reps = p.get("repeat", "0") == "1" + if not len(p["label"]) > 0: + alab = p["CL"] + else: + alab = p["label"] + aninput = gxtp.DataParam( + newname, + optional=False, + label=alab, + help=p["help"], + format=newfmt, + multiple=False, + num_dashes=ndash, + ) + aninput.positional = self.is_positional + if self.is_positional: + if p["origCL"].upper() == "STDIN": + aninput.positional = 9999998 + aninput.command_line_override = "< $%s" % newname + else: + aninput.positional = int(p["origCL"]) + aninput.command_line_override = "$%s" % newname + if reps: + repe = gxtp.Repeat( + name=f"R_{newname}", title=f"Add as many {alab} as needed" + ) + repe.append(aninput) + self.tinputs.append(repe) + tparm = gxtp.TestRepeat(name=f"R_{newname}") + tparm2 = gxtp.TestParam(newname, value="%s_sample" % newname) + tparm.append(tparm2) + self.testparam.append(tparm) + else: + self.tinputs.append(aninput) + tparm = gxtp.TestParam(newname, value="%s_sample" % newname) + self.testparam.append(tparm) + for p in self.addpar: + newname = p["name"] + newval = p["value"] + newlabel = p["label"] + newhelp = p["help"] + newtype = p["type"] + newcl = p["CL"] + oldcl = p["origCL"] + reps = p["repeat"] == "1" + if not len(newlabel) > 0: + newlabel = newname + ndash = self.getNdash(newname) + if newtype == "text": + aparm = gxtp.TextParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "integer": + aparm = gxtp.IntegerParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "float": + aparm = gxtp.FloatParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "boolean": + aparm = gxtp.BooleanParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + else: + raise ValueError( + 'Unrecognised parameter type "%s" for\ + additional parameter %s in makeXML' + % (newtype, newname) + ) + aparm.positional = self.is_positional + if self.is_positional: + aparm.positional = int(oldcl) + if reps: + repe = gxtp.Repeat( + name=f"R_{newname}", title=f"Add as many {newlabel} as needed" + ) + repe.append(aparm) + self.tinputs.append(repe) + tparm = gxtp.TestRepeat(name=f"R_{newname}") + tparm2 = gxtp.TestParam(newname, value=newval) + tparm.append(tparm2) + self.testparam.append(tparm) + else: + self.tinputs.append(aparm) + tparm = gxtp.TestParam(newname, value=newval) + self.testparam.append(tparm) + for p in self.selpar: + newname = p["name"] + newval = p["value"] + newlabel = p["label"] + newhelp = p["help"] + newtype = p["type"] + newcl = p["CL"] + if not len(newlabel) > 0: + newlabel = newname + ndash = self.getNdash(newname) + if newtype == "selecttext": + newtext = p["texts"] + aparm = gxtp.SelectParam( + newname, + label=newlabel, + help=newhelp, + num_dashes=ndash, + ) + for i in range(len(newval)): + anopt = gxtp.SelectOption( + value=newval[i], + text=newtext[i], + ) + aparm.append(anopt) + aparm.positional = self.is_positional + if self.is_positional: + aparm.positional = int(newcl) + self.tinputs.append(aparm) + tparm = gxtp.TestParam(newname, value=newval) + self.testparam.append(tparm) + else: + raise ValueError( + 'Unrecognised parameter type "%s" for\ + selecttext parameter %s in makeXML' + % (newtype, newname) + ) + for p in self.collections: + newkind = p["kind"] + newname = p["name"] + newlabel = p["label"] + newdisc = p["discover"] + collect = gxtp.OutputCollection(newname, label=newlabel, type=newkind) + disc = gxtp.DiscoverDatasets( + pattern=newdisc, directory=f"{newname}", visible="false" + ) + collect.append(disc) + self.toutputs.append(collect) + try: + tparm = gxtp.TestOutputCollection(newname) # broken until PR merged. + self.testparam.append(tparm) + except Exception: + print( + "#### WARNING: Galaxyxml version does not have the PR merged yet - tests for collections must be over-ridden until then!" + ) + + def doNoXMLparam(self): + """filter style package - stdin to stdout""" + if len(self.infiles) > 0: + alab = self.infiles[0]["label"] + if len(alab) == 0: + alab = self.infiles[0]["infilename"] + max1s = ( + "Maximum one input if parampass is 0 but multiple input files supplied - %s" + % str(self.infiles) + ) + assert len(self.infiles) == 1, max1s + newname = self.infiles[0]["infilename"] + aninput = gxtp.DataParam( + newname, + optional=False, + label=alab, + help=self.infiles[0]["help"], + format=self.infiles[0]["format"], + multiple=False, + num_dashes=0, + ) + aninput.command_line_override = "< $%s" % newname + aninput.positional = True + self.tinputs.append(aninput) + tp = gxtp.TestParam(name=newname, value="%s_sample" % newname) + self.testparam.append(tp) + if len(self.outfiles) > 0: + newname = self.outfiles[0]["name"] + newfmt = self.outfiles[0]["format"] + anout = gxtp.OutputData(newname, format=newfmt, num_dashes=0) + anout.command_line_override = "> $%s" % newname + anout.positional = self.is_positional + self.toutputs.append(anout) + tp = gxtp.TestOutput(name=newname, value="%s_sample" % newname) + self.testparam.append(tp) + + def makeXML(self): # noqa + """ + Create a Galaxy xml tool wrapper for the new script + Uses galaxyhtml + Hmmm. How to get the command line into correct order... + """ + if self.command_override: + self.newtool.command_override = self.command_override # config file + else: + self.newtool.command_override = self.xmlcl + cite = gxtp.Citations() + acite = gxtp.Citation(type="doi", value="10.1093/bioinformatics/bts573") + cite.append(acite) + self.newtool.citations = cite + safertext = "" + if self.args.help_text: + helptext = open(self.args.help_text, "r").readlines() + safertext = "\n".join([cheetah_escape(x) for x in helptext]) + if len(safertext.strip()) == 0: + safertext = ( + "Ask the tool author (%s) to rebuild with help text please\n" + % (self.args.user_email) + ) + if self.args.script_path: + if len(safertext) > 0: + safertext = safertext + "\n\n------\n" # transition allowed! + scr = [x for x in self.spacedScript if x.strip() > ""] + scr.insert(0, "\n\nScript::\n") + if len(scr) > 300: + scr = ( + scr[:100] + + [" >300 lines - stuff deleted", " ......"] + + scr[-100:] + ) + scr.append("\n") + safertext = safertext + "\n".join(scr) + self.newtool.help = safertext + self.newtool.version_command = f'echo "{self.args.tool_version}"' + std = gxtp.Stdios() + std1 = gxtp.Stdio() + std.append(std1) + self.newtool.stdios = std + requirements = gxtp.Requirements() + self.condaenv = [] + if self.args.packages: + try: + for d in self.args.packages.split(","): + ver = None + packg = None + d = d.replace("==", ":") + d = d.replace("=", ":") + if ":" in d: + packg, ver = d.split(":") + ver = ver.strip() + packg = packg.strip() + else: + packg = d.strip() + ver = None + if ver == "": + ver = None + if packg: + requirements.append( + gxtp.Requirement("package", packg.strip(), ver) + ) + self.condaenv.append(d) + except Exception: + print( + "### malformed packages string supplied - cannot parse =", + self.args.packages, + ) + sys.exit(2) + self.newtool.requirements = requirements + if self.args.parampass == "0": + self.doNoXMLparam() + else: + self.doXMLparam() + self.newtool.outputs = self.toutputs + self.newtool.inputs = self.tinputs + if self.args.script_path: + configfiles = gxtp.Configfiles() + configfiles.append( + gxtp.Configfile(name="runme", text="\n".join(self.escapedScript)) + ) + self.newtool.configfiles = configfiles + tests = gxtp.Tests() + test_a = gxtp.Test() + for tp in self.testparam: + test_a.append(tp) + tests.append(test_a) + self.newtool.tests = tests + self.newtool.add_comment( + "Created by %s at %s using the Galaxy Tool Factory." + % (self.args.user_email, timenow()) + ) + self.newtool.add_comment("Source in git at: %s" % (toolFactoryURL)) + exml0 = self.newtool.export() + exml = exml0.replace(FAKEEXE, "") # temporary work around until PR accepted + if ( + self.test_override + ): # cannot do this inside galaxyxml as it expects lxml objects for tests + part1 = exml.split("<tests>")[0] + part2 = exml.split("</tests>")[1] + fixed = "%s\n%s\n%s" % (part1, "\n".join(self.test_override), part2) + exml = fixed + with open("%s.xml" % self.tool_name, "w") as xf: + xf.write(exml) + xf.write("\n") + # galaxy history item + + def writeShedyml(self): + """for planemo""" + yuser = self.args.user_email.split("@")[0] + yfname = os.path.join(self.tooloutdir, ".shed.yml") + yamlf = open(yfname, "w") + odict = { + "name": self.tool_name, + "owner": yuser, + "type": "unrestricted", + "description": self.args.tool_desc, + "synopsis": self.args.tool_desc, + "category": "TF Generated Tools", + } + yaml.dump(odict, yamlf, allow_unicode=True) + yamlf.close() + + def makeTool(self): + """write xmls and input samples into place""" + if self.args.parampass == 0: + self.doNoXMLparam() + else: + self.makeXML() + if self.args.script_path: + stname = os.path.join(self.tooloutdir, self.sfile) + if not os.path.exists(stname): + shutil.copyfile(self.sfile, stname) + xreal = "%s.xml" % self.tool_name + xout = os.path.join(self.tooloutdir, xreal) + shutil.copyfile(xreal, xout) + xout = os.path.join(self.repdir, xreal) + shutil.copyfile(xreal, xout) + for p in self.infiles: + pth = p["name"] + dest = os.path.join(self.testdir, "%s_sample" % p["infilename"]) + shutil.copyfile(pth, dest) + dest = os.path.join( + self.repdir, "%s_sample.%s" % (p["infilename"], p["format"]) + ) + shutil.copyfile(pth, dest) + dest = os.path.join(self.local_tools, self.tool_name) + shutil.copytree(self.tooloutdir,dest, dirs_exist_ok=True) + + def makeToolTar(self, report_fail=False): + """move outputs into test-data and prepare the tarball""" + excludeme = "_planemo_test_report.html" + + def exclude_function(tarinfo): + filename = tarinfo.name + return None if filename.endswith(excludeme) else tarinfo + + for p in self.outfiles: + oname = p["name"] + tdest = os.path.join(self.testdir, "%s_sample" % oname) + src = os.path.join(self.testdir, oname) + if not os.path.isfile(tdest): + if os.path.isfile(src): + shutil.copyfile(src, tdest) + dest = os.path.join(self.repdir, "%s.sample.%s" % (oname,p['format'])) + shutil.copyfile(src, dest) + else: + if report_fail: + print( + "###Tool may have failed - output file %s not found in testdir after planemo run %s." + % (tdest, self.testdir) + ) + tf = tarfile.open(self.newtarpath, "w:gz") + tf.add( + name=self.tooloutdir, + arcname=self.tool_name, + filter=exclude_function, + ) + shutil.copy(self.newtarpath, os.path.join(self.tooloutdir, f"{self.tool_name}_untested_toolshed.gz")) + tf.close() + + + def planemo_test_update(self): + """planemo is a requirement so is available for testing + """ + xreal = "%s.xml" % self.tool_name + tool_test_path = os.path.join( + self.repdir, f"{self.tool_name}_planemo_test_report.html" + ) + if os.path.exists(self.tlog): + tout = open(self.tlog, "a") + else: + tout = open(self.tlog, "w") + cll = [ + "planemo", + "test", + "--conda_auto_init", + "--biocontainers", + "--test_data", + os.path.abspath(self.testdir), + "--test_output", + os.path.abspath(tool_test_path), + "--galaxy_root", + self.args.galaxy_root, + "--update_test_data", + os.path.abspath(xreal), + ] + p = subprocess.run( + cll, + shell=False, + cwd=self.tooloutdir, + stderr=tout, + stdout=tout, + ) + tout.close() + return p.returncode + + + def update_toolconf(self ): + + def sortchildrenby(parent, attr): + parent[:] = sorted(parent, key=lambda child: child.get(attr)) + + tcpath = os.path.join(self.args.galaxy_root,'config/local_tool_conf.xml') + xmlfile = os.path.join(self.local_tools, self.tool_name, '%s.xml' % self.tool_name) + parser = ET.XMLParser(remove_blank_text=True) + tree = ET.parse(tcpath, parser) + root = tree.getroot() + hasTF = False + e = root.findall("section") + if len(e) > 0: + hasTF = True + TFsection = e[0] + if not hasTF: + TFsection = ET.Element("section", {"id":"localtools", "name":"Local Tools"}) + root.insert(0, TFsection) # at the top! + our_tools = TFsection.findall("tool") + conf_tools = [x.attrib["file"] for x in our_tools] + if xmlfile not in conf_tools: # new + ET.SubElement(TFsection, "tool", {"file": xmlfile}) + sortchildrenby(TFsection,"file") + tree.write(tcpath, pretty_print=True) + + + + + + + def shedLoad(self): + """ + use bioblend to create new repository + or update existing + + """ + if os.path.exists(self.tlog): + sto = open(self.tlog, "a") + else: + sto = open(self.tlog, "w") + + ts = toolshed.ToolShedInstance( + url=self.args.toolshed_url, + key=self.args.toolshed_api_key, + verify=False, + ) + repos = ts.repositories.get_repositories() + rnames = [x.get("name", "?") for x in repos] + rids = [x.get("id", "?") for x in repos] + tfcat = "ToolFactory generated tools" + if self.tool_name not in rnames: + tscat = ts.categories.get_categories() + cnames = [x.get("name", "?").strip() for x in tscat] + cids = [x.get("id", "?") for x in tscat] + catID = None + if tfcat.strip() in cnames: + ci = cnames.index(tfcat) + catID = cids[ci] + res = ts.repositories.create_repository( + name=self.args.tool_name, + synopsis="Synopsis:%s" % self.args.tool_desc, + description=self.args.tool_desc, + type="unrestricted", + remote_repository_url=self.args.toolshed_url, + homepage_url=None, + category_ids=catID, + ) + tid = res.get("id", None) + sto.write(f"#create_repository {self.args.tool_name} tid={tid} res={res}\n") + else: + i = rnames.index(self.tool_name) + tid = rids[i] + try: + res = ts.repositories.update_repository( + id=tid, tar_ball_path=self.newtarpath, commit_message=None + ) + sto.write(f"#update res id {id} ={res}\n") + except ConnectionError: + sto.write( + "####### Is the toolshed running and the API key correct? Bioblend shed upload failed\n" + ) + sto.close() + + def eph_galaxy_load(self): + """ + use ephemeris to load the new tool from the local toolshed after planemo uploads it + """ + if os.path.exists(self.tlog): + tout = open(self.tlog, "a") + else: + tout = open(self.tlog, "w") + cll = [ + "shed-tools", + "install", + "-g", + self.args.galaxy_url, + "--latest", + "-a", + self.args.galaxy_api_key, + "--name", + self.tool_name, + "--owner", + "fubar", + "--toolshed", + self.args.toolshed_url, + "--section_label", + "ToolFactory", + ] + tout.write("running\n%s\n" % " ".join(cll)) + subp = subprocess.run( + cll, + env=self.ourenv, + cwd=self.ourcwd, + shell=False, + stderr=tout, + stdout=tout, + ) + tout.write( + "installed %s - got retcode %d\n" % (self.tool_name, subp.returncode) + ) + tout.close() + return subp.returncode + + def planemo_biodocker_test(self): + """planemo currently leaks dependencies if used in the same container and gets unhappy after a + first successful run. https://github.com/galaxyproject/planemo/issues/1078#issuecomment-731476930 + + Docker biocontainer has planemo with caches filled to save repeated downloads + + + """ + + def prun(container, tout, cl, user="biodocker"): + rlog = container.exec_run(cl, user=user) + slogl = str(rlog).split("\\n") + slog = "\n".join(slogl) + tout.write(f"## got rlog {slog} from {cl}\n") + + if os.path.exists(self.tlog): + tout = open(self.tlog, "a") + else: + tout = open(self.tlog, "w") + planemoimage = "quay.io/fubar2/planemo-biocontainer" + xreal = "%s.xml" % self.tool_name + repname = f"{self.tool_name}_planemo_test_report.html" + ptestrep_path = os.path.join(self.repdir, repname) + client = docker.from_env() + tvol = client.volumes.create() + tvolname = tvol.name + destdir = "/toolfactory/ptest" + imrep = os.path.join(destdir, repname) + # need to keep the container running so keep it open with sleep + # will stop and destroy it when we are done + container = client.containers.run( + planemoimage, + "sleep 120m", + detach=True, + user="biodocker", + volumes={f"{tvolname}": {"bind": "/toolfactory", "mode": "rw"}}, + ) + cl = f"mkdir -p {destdir}" + prun(container, tout, cl, user="root") + # that's how hard it is to get root on a biodocker container :( + cl = f"rm -rf {destdir}/*" + prun(container, tout, cl, user="root") + ptestpath = os.path.join(destdir, "tfout", xreal) + self.copy_to_container(self.tooloutdir, destdir, container) + cl = "chown -R biodocker /toolfactory" + prun(container, tout, cl, user="root") + _ = container.exec_run(f"ls -la {destdir}") + ptestcl = f"planemo test --test_output {imrep} --update_test_data --no_cleanup --test_data {destdir}/tfout/test-data --galaxy_root /home/biodocker/galaxy-central {ptestpath}" + try: + _ = container.exec_run(ptestcl) + # fails because test outputs missing but updates the test-data directory + except Exception: + e = sys.exc_info()[0] + tout.write(f"#### error: {e} from {ptestcl}\n") + cl = f"planemo test --test_output {imrep} --no_cleanup --test_data {destdir}/tfout/test-data --galaxy_root /home/biodocker/galaxy-central {ptestpath}" + try: + prun(container, tout, cl) + except Exception: + e = sys.exc_info()[0] + tout.write(f"#### error: {e} from {ptestcl}\n") + testouts = tempfile.mkdtemp(suffix=None, prefix="tftemp", dir=".") + self.copy_from_container(destdir, testouts, container) + src = os.path.join(testouts, "ptest") + if os.path.isdir(src): + shutil.copytree(src, ".", dirs_exist_ok=True) + src = repname + if os.path.isfile(repname): + shutil.copyfile(src, ptestrep_path) + else: + tout.write(f"No output from run to shutil.copytree in {src}\n") + tout.close() + container.stop() + container.remove() + tvol.remove() + shutil.rmtree(testouts) # leave for debugging + + + # def run(self): + # """ + # scripts must be small enough not to fill the pipe! + # """ + # if self.treatbashSpecial and self.opts.interpreter in ['bash','sh']: + # retval = self.runBash() + # else: + # if self.opts.output_dir: + # ste = open(self.elog,'w') + # sto = open(self.tlog,'w') + # sto.write('## Toolfactory generated command line = %s\n' % ' '.join(self.cl)) + # sto.flush() + # p = subprocess.Popen(self.cl,shell=False,stdout=sto,stderr=ste,stdin=subprocess.PIPE,cwd=self.opts.output_dir) + # else: + # p = subprocess.Popen(self.cl,shell=False,stdin=subprocess.PIPE) + # p.stdin.write(self.script) + # p.stdin.close() + # retval = p.wait() + # if self.opts.output_dir: + # sto.close() + # ste.close() + # err = open(self.elog,'r').read() + # if retval <> 0 and err: # problem + # print >> sys.stderr, '## error code %d returned with:\n%s' % (retval,err) + # if self.opts.make_HTML: + # self.makeHtml() + # return retval + + # def runBash(self): + # """ + # cannot use - for bash so use self.sfile + # """ + # if self.opts.output_dir: + # s = '## Toolfactory generated command line = %s\n' % ' '.join(self.cl) + # sto = open(self.tlog,'w') + # sto.write(s) + # sto.flush() + # p = subprocess.Popen(self.cl,shell=False,stdout=sto,stderr=sto,cwd=self.opts.output_dir) + # else: + # p = subprocess.Popen(self.cl,shell=False) + # retval = p.wait() + # if self.opts.output_dir: + # sto.close() + # if self.opts.make_HTML: + # self.makeHtml() + # return retval + + # def make_conda_env(self, dep_list): + # """ +# (venv) galaxy@ross-newgrt:/evol/galaxy$ mulled-hash bioblend=0.17.0,galaxyxml=0.4.14 +# mulled-v2-37438395e15c3d0bed4e02d66d5b05ca3d18b389:1d0b008b65909163243b3fdddd9aa20605f8a005 + +# conda create -n myenv python=3.9 scipy=0.17.3 astroid babel + + + # """ + # dep_list.sort() + # self.env_name = '-'.join(dep_list) + # for e in self.xmlcl + + + # for e in self.xclsuffix: + # # xappendme = ["999", p["infilename"], "< $%s" % p["infilename"]] + # else: + # xappendme = [p["CL"], "$%s" % p["infilename"], ""] + # xclsuffix.append(xappendme) + # if os.path.exists(self.tlog): + # tout = open(self.tlog, "a") + # else: + # tout = open(self.tlog, "w") + # cli = ["conda", "create", "-n", self.env_name, ' '.join(dep_list)] + # p = subprocess.run( + # cll, + # shell=False, + # cwd=self.tooloutdir, + # stderr=tout, + # stdout=tout, + # ) + # cli = ["conda", "activate", self.env_name, " && "] + # cli.append(run_cmd) + # tout.close() + +def main(): + """ + This is a Galaxy wrapper. + It expects to be called by a special purpose tool.xml + + """ + parser = argparse.ArgumentParser() + a = parser.add_argument + a("--script_path", default=None) + a("--history_test", default=None) + a("--cl_user_suffix", default=None) + a("--sysexe", default=None) + a("--packages", default=None) + a("--tool_name", default="newtool") + a("--tool_dir", default=None) + a("--input_files", default=[], action="append") + a("--output_files", default=[], action="append") + a("--user_email", default="Unknown") + a("--bad_user", default=None) + a("--help_text", default=None) + a("--tool_desc", default=None) + a("--tool_version", default="0.01") + a("--citations", default=None) + a("--command_override", default=None) + a("--test_override", default=None) + a("--additional_parameters", action="append", default=[]) + a("--selecttext_parameters", action="append", default=[]) + a("--edit_additional_parameters", action="store_true", default=False) + a("--parampass", default="positional") + a("--tfout", default="./tfout") + a("--galaxy_root", default="/galaxy-central") + a("--galaxy_venv", default="/galaxy_venv") + a("--collection", action="append", default=[]) + a("--include_tests", default=False, action="store_true") + a("--install_flag", action = "store_true", default=False) + a("--admin_only", default=True, action="store_true") + a("--untested_tool_out", default=None) + a("--local_tools", default="tools") # relative to $__root_dir__ + a("--tool_conf_path", default="config/tool_conf.xml") # relative to $__root_dir__ + args = parser.parse_args() + if args.admin_only: + assert not args.bad_user, ( + 'UNAUTHORISED: %s is NOT authorized to use this tool until Galaxy \ +admin adds %s to "admin_users" in the galaxy.yml Galaxy configuration file' + % (args.bad_user, args.bad_user) + ) + assert args.tool_name, "## This ToolFactory cannot build a tool without a tool name. Please supply one." + tf = Tool_Factory(args) + tf.writeShedyml() + tf.makeTool() + tf.planemo_test_update() + tf.makeToolTar() + tf.update_toolconf() + + +if __name__ == "__main__": + main()
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/pyrev_pos_test/test-data/pyrev_positionalparse_output_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1210 @@ +yrotcafloot/2rabuf/moc.buhtig//:sptth ees # +# +2102 yaM )moc pots liamg ta surazal pots ssor( surazal ssor thgirypoc # +# +devreser sthgir lla # +LPGL eht rednu desneciL # +ta emoclew sexif gub dna tnemevorpmi rof snoitseggus # +yrotcafloot/2rabuf/moc.buhtig//:sptth # +# +llatsni/tset dna etareneg - sloot owt otni derotcafeR :2202 hcram # +noitpoda reniatnocoib dna tnempoleved lairotut NTG fo trap sa # +stuptuo tset eht setaerc ,evihcra detset-non a no omenalp snur retset ehT # +.tset htiw loot reporp wen a snruter dna # + + + +esrapgra tropmi +ypoc tropmi +ltncf tropmi +nosj tropmi +so tropmi +er tropmi +xelhs tropmi +lituhs tropmi +ssecorpbus tropmi +sys tropmi +elifrat tropmi +elifpmet tropmi +emit tropmi + +yxalag tropmi dnelboib morf + +txg sa loot.lmxyxalag tropmi +ptxg sa sretemarap.loot.lmxyxalag tropmi + +TE sa eerte.lmxl tropmi + +lmay tropmi + +"2202 hcraM 4.2V" = noisrevym +eurT = esobrev +eurT = gubed +"yrotcafloot/2rabuf/moc.buhtig//:sptth" = LRUyrotcaFloot +"~~~EM~~~EVOMER~~~" = EXEEKAF +neve exe eht gnidneperp lmxyxalag xif ot pmub noisrev/RP a litnu siht deen # +.edirrevo htiw # + + +:)(wonemit fed +"""gnirts a sa emit tnerruc nruter""" +)))(emit.emit(emitlacol.emit ,"S%:M%:H% Y%/m%/d%"(emitfrts.emit nruter + + +}"#\\" :"#" ,"$\\" :"$"{ = elbat_epacse_hateehc + + +:)txet(epacse_hateehc fed +""".txet nihtiw seititne ecudorP""" +)]txet ni c rof )c ,c(teg.elbat_epacse_hateehc[(nioj."" nruter + + +:)txet_snoitatic(snoitatic_esrap fed +"""""" +])(pirts.c fi )"**YRTNE**"(tilps.txet_snoitatic ni c rof c[ = snoitatic +][ = selput_noitatic +:snoitatic ni noitatic rof +:)"iod"(htiwstrats.noitatic fi +)))(pirts.]: )"iod"(nel[noitatic ,"iod"((dneppa.selput_noitatic +:esle +)))(pirts.]: )"xetbib"(nel[noitatic ,"xetbib"((dneppa.selput_noitatic +selput_noitatic nruter + + +:yrotcaF_looT ssalc +tpircs yrartibra na rof repparW""" +lmxyxalag sesu + +""" + +aqon # :)enoN=sgra ,fles(__tini__ fed +""" +ereh loot eht gninnur rof lc enil dnammoc eraperp +noitareneg loot lmxyxalag rof dedeen stnemele eraperp dna +""" +)'sloot_lacol',toor_yxalag.sgra(nioj.htap.so = sloot_lacol.fles +)(dwcteg.so = dwcruo.fles +][ = snoitcelloc.fles +:0 > )noitcelloc.sgra(nel fi +:yrt +[ = snoitcelloc.fles +1 > ))(pirts.x(nel fi noitcelloc.sgra ni x rof )x(sdaol.nosj +] +:noitpecxE tpecxe +(tnirp +"yranoitcid a eb dluohs - demroflam si })noitcelloc.sgra(rts{ retemarap snoitcelloc--"f +) +:yrt +[ = selifni.fles +1 > ))(pirts.x(nel fi selif_tupni.sgra ni x rof )x(sdaol.nosj +] +:noitpecxE tpecxe +(tnirp +"yranoitcid a eb dluohs - demroflam si })selif_tupni.sgra(rts{ retemarap selif_tupni--"f +) +:yrt +[ = seliftuo.fles +1 > ))(pirts.x(nel fi selif_tuptuo.sgra ni x rof )x(sdaol.nosj +] +:noitpecxE tpecxe +(tnirp +"yranoitcid a eb dluohs - demroflam si }selif_tuptuo.sgra{ retemarap selif_tuptuo--"f +) +'tros emos fo tuptuo na tuohtiw liaf lliw rennur boj yxalaG ehT .deificeps snoitcelloc tuptuo ro seliftuo oN' ,0 > ))snoitcelloc.fles(nel + )seliftuo.fles(nel( tressa +:yrt +[ = rapdda.fles +1 > ))(pirts.x(nel fi sretemarap_lanoitidda.sgra ni x rof )x(sdaol.nosj +] +:noitpecxE tpecxe +(tnirp +"yranoitcid a eb dluohs - demroflam si }sretemarap_lanoitidda.sgra{ sretemarap_lanoitidda--"f +) +:yrt +[ = raples.fles +1 > ))(pirts.x(nel fi sretemarap_txettceles.sgra ni x rof )x(sdaol.nosj +] +:noitpecxE tpecxe +(tnirp +"yranoitcid a eb dluohs - demroflam si }sretemarap_txettceles.sgra{ sretemarap_txettceles--"f +) +sgra = sgra.fles +)(rappunaelc.fles +enoN = tceriderlcxtsal.fles +][ = lclmx.fles +"lanoitisop" == ssapmarap.sgra.fles = lanoitisop_si.fles +:exesys.sgra.fles fi +:exesys.sgra.fles ni " " fi +)exesys.sgra.fles(tilps.xelhs = emetucexe.fles +:esle +[ = emetucexe.fles +,exesys.sgra.fles +] +:esle +:segakcap.sgra.fles fi +[ = emetucexe.fles +,)(pirts.]0[)":"(tilps.]0[)","(tilps.segakcap.sgra.fles +] +:esle +enoN = emetucexe.fles +dneppa.lclmx.fles = LCXa +[ ni ssapmarap.sgra tressa +,"0" +,"esrapgra" +,"lanoitisop" +'"esrapgra" ro "lanoitisop","0" eb tsum ssapmarap.sgra' ,] +)eman_loot.sgra ,"" ,"+]_9-0Z-Az-a^["(bus.er = eman_loot.fles +eman_loot.fles = di_loot.fles +(looT.txg = lootwen.fles +,eman_loot.fles +,di_loot.fles +,noisrev_loot.sgra.fles +,csed_loot.sgra.fles +,EXEEKAF +) +"tuoft/." = ridtuoloot.fles +"negloot/." = ridper.fles +)eman_loot.fles % "zg.dehsloot_detset_ton_s%" ,ridtuoloot.fles(nioj.htap.so # tuo_loot_detsetnu.sgra = htapratwen.fles +)"atad-tset" ,ridtuoloot.fles(nioj.htap.so = ridtset.fles +:)ridtuoloot.fles(stsixe.htap.so ton fi +)ridtuoloot.fles(ridkm.so +:)ridtset.fles(stsixe.htap.so ton fi +)ridtset.fles(ridkm.so +:)ridper.fles(stsixe.htap.so ton fi +)ridper.fles(ridkm.so +)eman_loot.fles % 'txt.gol_nur_FT_s%',ridper.fles(nioj.htap.so = golt.fles +)(stupnI.ptxg = stupnit.fles +)(stuptuO.ptxg = stuptuot.fles +][ = maraptset.fles +:htap_tpircs.sgra.fles fi +)(tpircSperp.fles +:edirrevo_dnammoc.sgra.fles fi +)(senildaer.)"r" ,edirrevo_dnammoc.sgra.fles(nepo = socs +]socs ni x rof )(pirtsr.x[ = edirrevo_dnammoc.fles +:esle +enoN = edirrevo_dnammoc.fles +:edirrevo_tset.sgra.fles fi +)(senildaer.)"r" ,edirrevo_tset.sgra.fles(nepo = sots +]sots ni x rof )(pirtsr.x[ = edirrevo_tset.fles +:esle +enoN = edirrevo_tset.fles +:htap_tpircs.sgra.fles fi +:emetucexe.fles ni xe rof +)xe(LCXa +)"emnur$"(LCXa +:esle +:emetucexe.fles ni xe rof +)xe(LCXa + +:"0" == ssapmarap.sgra.fles fi +)(elpmislc.fles +:esle +:"lanoitisop" == ssapmarap.sgra.fles fi +)(soplcperp.fles +)(lanoitisoplc.fles +:esle +)(pgraperp.fles +)(esrapgralc.fles + +:)fles(elpmislc fed +"""o/i rof > dna < sesu - staeper ro sretemarap on""" +dneppa.lclmx.fles = LCXa +:0 > )selifni.fles(nel fi +)"<"(LCXa +)]"emanelifni"[]0[selifni.fles % "s%$"(LCXa +:0 > )seliftuo.fles(nel fi +)">"(LCXa +)]"eman"[]0[seliftuo.fles % "s%$"(LCXa +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +:plc ni c rof +)c(LCXa + +:)fles(pgraperp fed +][ = xiffuslcx +:)selifni.fles(etaremune ni p ,i rof +]"emanelifni"[p = man +:"NIDTS" == )(reppu.)(pirts.]"LCgiro"[p fi +[ = emdneppax +,man +,man +,man % "s%$ <" +] +:esle +"1" == ]"taeper"[p = per +"" = revo +:per fi +'rof dne#n\"}man{.per$" }man{--n\:}man{_R$ ni per$ rof#'f = revo +]revo ,]"LC"[p % "s%$" ,]"LC"[p[ = emdneppax +)emdneppax(dneppa.xiffuslcx +:)seliftuo.fles(etaremune ni p ,i rof +:"TUODTS" == )(reppu.)(pirts.]"LCgiro"[p fi +]]"eman"[p % "s%$" ,">"[ = tceriderlcxtsal.fles +:esle +)]"" ,]"eman"[p % "s%$" ,]"eman"[p[(dneppa.xiffuslcx +:rapdda.fles ni p rof +]"eman"[p = man +"1" == ]"taeper"[p = per +:per fi +'rof dne#n\"}man{.per$" }man{--n\:}man{_R$ ni per$ rof#'f = revo +:esle +]"edirrevo"[p = revo +)]revo ,man % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +:raples.fles ni p rof +)]]"edirrevo"[p ,]"eman"[p % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +xiffuslcx = xiffuslcx.fles + +:)fles(soplcperp fed +][ = xiffuslcx +:)selifni.fles(etaremune ni p ,i rof +:"NIDTS" == )(reppu.)(pirts.]"LCgiro"[p fi +[ = emdneppax +,"999" +,]"emanelifni"[p +,]"emanelifni"[p % "s%$ <" +] +:esle +]"" ,]"emanelifni"[p % "s%$" ,]"LC"[p[ = emdneppax +)emdneppax(dneppa.xiffuslcx +:)seliftuo.fles(etaremune ni p ,i rof +:"TUODTS" == )(reppu.)(pirts.]"LCgiro"[p fi +]]"eman"[p % "s%$" ,">"[ = tceriderlcxtsal.fles +:esle +)]"" ,]"eman"[p % "s%$" ,]"LC"[p[(dneppa.xiffuslcx +:rapdda.fles ni p rof +]"eman"[p = man +esnes ON ekam staeper # "1" == ]"taeper"[p = per +:per fi +(tnirp +"!senil dnammoc retemarap lanoitisop ni dettimrep ton - derongi }man{ rof staepeR .gninraw ###"f +) +]"edirrevo"[p = revo +)]revo ,man % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +:raples.fles ni p rof +)]]"edirrevo"[p ,]"eman"[p % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +)(tros.xiffuslcx +xiffuslcx = xiffuslcx.fles + +:)fles(tpircSperp fed +)(senildaer.)"r" ,htap_tpircs.sgra.fles(nepo = xr +]xr ni x rof )(pirtsr.x[ = xr +]"" > )(pirts.x fi xr ni x rof )(pirts.x[ = kcehcxr +"nur tonnaC .ytpme si tpircs deilppuS" ,0 > )kcehcxr(nel tressa +)xr(nioj."n\" = tpircs.fles +(pmetskm.elifpmet = elifs.fles ,eldnahf +)]0[emetucexe.fles( % "s%_"=xiffus ,eman_loot.fles=xiferp +) +)"w" ,elifs.fles(nepo = tpircst +)tpircs.fles(etirw.tpircst +)(esolc.tpircst +]"" > )(pirts.x fi xr ni x rof "}x{ "f[ = tpircSdecaps.fles +)"war#" ,0(tresni.xr +)"war dne#"(dneppa.xr +xr = tpircSdepacse.fles +)]0[emetucexe.fles ,eman_loot.fles( % "s%.s%" = tra +)"bw" ,tra(nepo = tcafitra +))"8ftu" ,tpircs.fles(setyb(etirw.tcafitra +)(esolc.tcafitra + +:)fles(rappunaelc fed +"""lanidro ciremun rieht yb detacilpmoc era sretemarap lanoitisop """ +:"lanoitisop" == ssapmarap.sgra.fles fi +:)selifni.fles(etaremune ni p ,i rof +( tressa +"NIDTS" == )(reppu.)(pirts.]"LC"[p ro )(tigidsi.]"LC"[p +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,) +,]"LC"[p +,]"lebal"[p +) +:)seliftuo.fles(etaremune ni p ,i rof +( tressa +"TUODTS" == )(reppu.)(pirts.]"LC"[p ro )(tigidsi.]"LC"[p +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,) +,]"LC"[p +,]"eman"[p +) +:)rapdda.fles(etaremune ni p ,i rof +[p tressa +"LC" +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,)(tigidsi.] +,]"LC"[p +,]"eman"[p +) +:)selifni.fles(etaremune ni p ,i rof +)p(ypoc.ypoc = pfni +]"LC"[pfni = ]"LCgiro"[pfni +:]"0" ,"lanoitisop"[ ni ssapmarap.sgra.fles fi +)"_" ," "(ecalper.]"lebal"[pfni = ]"emanelifni"[pfni +:esle +]"LC"[pfni = ]"emanelifni"[pfni +pfni = ]i[selifni.fles +:)seliftuo.fles(etaremune ni p ,i rof +)p(ypoc.ypoc = pftuo +ypoc peek # ]"LC"[pftuo = ]"LCgiro"[pftuo +pftuo = ]i[seliftuo.fles +:)rapdda.fles(etaremune ni p ,i rof +)p(ypoc.ypoc = pdda +]"LC"[pdda = ]"LCgiro"[pdda +pdda = ]i[rapdda.fles + +:)fles(lanoitisoplc fed +smarap neht redro ni stupni # +dneppa.lclmx.fles = LCXa +:xiffuslcx.fles ni )edirrevok ,v ,k( rof +)v(LCXa +:tceriderlcxtsal.fles fi +:tceriderlcxtsal.fles ni lc rof +)lc(LCXa +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +:plc ni c rof +)c(LCXa + +:)fles(esrapgralc fed +"""elyts esrapgra""" +dneppa.lclmx.fles = LCXa +mrof deman esrapgra ni smarap neht stupni # + +:xiffuslcx.fles ni )edirrevok ,v ,k( rof +:"" > edirrevok fi +edirrevok = k +)k(LCXa +:esle +:1 == ))(pirts.k(nel fi +k % "s%-" = k +:esle +k % "s%--" = k +)k(LCXa +)v(LCXa +:tceriderlcxtsal.fles fi +:tceriderlcxtsal.fles ni lc rof +)lc(LCXa +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +:plc ni c rof +)c(LCXa + +:)emanwen ,fles(hsadNteg fed +:lanoitisop_si.fles fi +0 = hsadn +:esle +2 = hsadn +:2 < )emanwen(nel fi +1 = hsadn +hsadn nruter + +aqon # :)fles(marapLMXod fed +"""loot ot stnemele dedeen lla ddA""" +:seliftuo.fles ni p rof +]"eman"[p = emanwen +]"tamrof"[p = tmfwen +]"LC"[p = lcwen +]"tset"[p = tset +]"LCgiro"[p = lcdlo +)(pirts.tset = tset +)lcwen(hsadNteg.fles = hsadn +(ataDtuptuO.ptxg = mrapa +emanwen=lebal ,hsadn=sehsad_mun ,tmfwen=tamrof ,emanwen=eman +) +lanoitisop_si.fles = lanoitisop.mrapa +:lanoitisop_si.fles fi +:"TUODTS" == )(reppu.lcdlo fi +9999999 = lanoitisop.mrapa +emanwen % "s%$ >" = edirrevo_enil_dnammoc.mrapa +:esle +)lcdlo(tni = lanoitisop.mrapa +emanwen % "s%$" = edirrevo_enil_dnammoc.mrapa +)mrapa(dneppa.stuptuot.fles +enoN = dl +:"" > )(pirts.tset fi +:)"ffid"(htiwstrats.)(pirts.tset fi +"ffid" = c +0 = dl +:tigidsi.]1[)":"(tilps.tset fi +)]1[)":"(tilps.tset(tni = dl +(tuptuOtseT.ptxg = pt +,emanwen=eman +,emanwen % "elpmas_s%"=eulav +,c=erapmoc +,dl=ffid_senil +) +:)"ezis_mis"(htiwstrats.tset file +"ezis_mis" = c +)(pirts.]1[)":"(tilps.tset = nt +:"" > nt fi +:nt ni "." fi +enoN = atled +))nt(taolf ,0.1(nim = carf_atled +:esle +)nt(tni = atled +enoN = carf_atled +(tuptuOtseT.ptxg = pt +,emanwen=eman +,emanwen % "elpmas_s%"=eulav +,c=erapmoc +,atled=atled +,carf_atled=carf_atled +) +:esle +tset = c +(tuptuOtseT.ptxg = pt +,emanwen=eman +,emanwen % "elpmas_s%"=eulav +,c=erapmoc +) +)pt(dneppa.maraptset.fles +:selifni.fles ni p rof +]"emanelifni"[p = emanwen +]"tamrof"[p = tmfwen +)emanwen(hsadNteg.fles = hsadn +"1" == )"0" ,"taeper"(teg.p = sper +:0 > )]"lebal"[p(nel ton fi +]"LC"[p = bala +:esle +]"lebal"[p = bala +(maraPataD.ptxg = tupnina +,emanwen +,eslaF=lanoitpo +,bala=lebal +,]"pleh"[p=pleh +,tmfwen=tamrof +,eslaF=elpitlum +,hsadn=sehsad_mun +) +lanoitisop_si.fles = lanoitisop.tupnina +:lanoitisop_si.fles fi +:"NIDTS" == )(reppu.]"LCgiro"[p fi +8999999 = lanoitisop.tupnina +emanwen % "s%$ <" = edirrevo_enil_dnammoc.tupnina +:esle +)]"LCgiro"[p(tni = lanoitisop.tupnina +emanwen % "s%$" = edirrevo_enil_dnammoc.tupnina +:sper fi +(taepeR.ptxg = eper +"dedeen sa }bala{ ynam sa ddA"f=eltit ,"}emanwen{_R"f=eman +) +)tupnina(dneppa.eper +)eper(dneppa.stupnit.fles +)"}emanwen{_R"f=eman(taepeRtseT.ptxg = mrapt +)emanwen % "elpmas_s%"=eulav ,emanwen(maraPtseT.ptxg = 2mrapt +)2mrapt(dneppa.mrapt +)mrapt(dneppa.maraptset.fles +:esle +)tupnina(dneppa.stupnit.fles +)emanwen % "elpmas_s%"=eulav ,emanwen(maraPtseT.ptxg = mrapt +)mrapt(dneppa.maraptset.fles +:rapdda.fles ni p rof +]"eman"[p = emanwen +]"eulav"[p = lavwen +]"lebal"[p = lebalwen +]"pleh"[p = plehwen +]"epyt"[p = epytwen +]"LC"[p = lcwen +]"LCgiro"[p = lcdlo +"1" == ]"taeper"[p = sper +:0 > )lebalwen(nel ton fi +emanwen = lebalwen +)emanwen(hsadNteg.fles = hsadn +:"txet" == epytwen fi +(maraPtxeT.ptxg = mrapa +,emanwen +,lebalwen=lebal +,plehwen=pleh +,lavwen=eulav +,hsadn=sehsad_mun +) +:"regetni" == epytwen file +(maraPregetnI.ptxg = mrapa +,emanwen +,lebalwen=lebal +,plehwen=pleh +,lavwen=eulav +,hsadn=sehsad_mun +) +:"taolf" == epytwen file +(maraPtaolF.ptxg = mrapa +,emanwen +,lebalwen=lebal +,plehwen=pleh +,lavwen=eulav +,hsadn=sehsad_mun +) +:"naeloob" == epytwen file +(maraPnaelooB.ptxg = mrapa +,emanwen +,lebalwen=lebal +,plehwen=pleh +,lavwen=eulav +,hsadn=sehsad_mun +) +:esle +(rorrEeulaV esiar +\rof "s%" epyt retemarap desingocernU' +'LMXekam ni s% retemarap lanoitidda +)emanwen ,epytwen( % +) +lanoitisop_si.fles = lanoitisop.mrapa +:lanoitisop_si.fles fi +)lcdlo(tni = lanoitisop.mrapa +:sper fi +(taepeR.ptxg = eper +"dedeen sa }lebalwen{ ynam sa ddA"f=eltit ,"}emanwen{_R"f=eman +) +)mrapa(dneppa.eper +)eper(dneppa.stupnit.fles +)"}emanwen{_R"f=eman(taepeRtseT.ptxg = mrapt +)lavwen=eulav ,emanwen(maraPtseT.ptxg = 2mrapt +)2mrapt(dneppa.mrapt +)mrapt(dneppa.maraptset.fles +:esle +)mrapa(dneppa.stupnit.fles +)lavwen=eulav ,emanwen(maraPtseT.ptxg = mrapt +)mrapt(dneppa.maraptset.fles +:raples.fles ni p rof +]"eman"[p = emanwen +]"eulav"[p = lavwen +]"lebal"[p = lebalwen +]"pleh"[p = plehwen +]"epyt"[p = epytwen +]"LC"[p = lcwen +:0 > )lebalwen(nel ton fi +emanwen = lebalwen +)emanwen(hsadNteg.fles = hsadn +:"txettceles" == epytwen fi +]"stxet"[p = txetwen +(maraPtceleS.ptxg = mrapa +,emanwen +,lebalwen=lebal +,plehwen=pleh +,hsadn=sehsad_mun +) +:))lavwen(nel(egnar ni i rof +(noitpOtceleS.ptxg = tpona +,]i[lavwen=eulav +,]i[txetwen=txet +) +)tpona(dneppa.mrapa +lanoitisop_si.fles = lanoitisop.mrapa +:lanoitisop_si.fles fi +)lcwen(tni = lanoitisop.mrapa +)mrapa(dneppa.stupnit.fles +)lavwen=eulav ,emanwen(maraPtseT.ptxg = mrapt +)mrapt(dneppa.maraptset.fles +:esle +(rorrEeulaV esiar +\rof "s%" epyt retemarap desingocernU' +'LMXekam ni s% retemarap txettceles +)emanwen ,epytwen( % +) +:snoitcelloc.fles ni p rof +]"dnik"[p = dnikwen +]"eman"[p = emanwen +]"lebal"[p = lebalwen +]"revocsid"[p = csidwen +)dnikwen=epyt ,lebalwen=lebal ,emanwen(noitcelloCtuptuO.ptxg = tcelloc +(stesataDrevocsiD.ptxg = csid +"eslaf"=elbisiv ,"}emanwen{"f=yrotcerid ,csidwen=nrettap +) +)csid(dneppa.tcelloc +)tcelloc(dneppa.stuptuot.fles +:yrt +.degrem RP litnu nekorb # )emanwen(noitcelloCtuptuOtseT.ptxg = mrapt +)mrapt(dneppa.maraptset.fles +:noitpecxE tpecxe +(tnirp +"!neht litnu neddir-revo eb tsum snoitcelloc rof stset - tey degrem RP eht evah ton seod noisrev lmxyxalaG :GNINRAW ####" +) + +:)fles(marapLMXoNod fed +"""tuodts ot nidts - egakcap elyts retlif""" +:0 > )selifni.fles(nel fi +]"lebal"[]0[selifni.fles = bala +:0 == )bala(nel fi +]"emanelifni"[]0[selifni.fles = bala +( = s1xam +"s% - deilppus selif tupni elpitlum tub 0 si ssapmarap fi tupni eno mumixaM" +)selifni.fles(rts % +) +s1xam ,1 == )selifni.fles(nel tressa +]"emanelifni"[]0[selifni.fles = emanwen +(maraPataD.ptxg = tupnina +,emanwen +,eslaF=lanoitpo +,bala=lebal +,]"pleh"[]0[selifni.fles=pleh +,]"tamrof"[]0[selifni.fles=tamrof +,eslaF=elpitlum +,0=sehsad_mun +) +emanwen % "s%$ <" = edirrevo_enil_dnammoc.tupnina +eurT = lanoitisop.tupnina +)tupnina(dneppa.stupnit.fles +)emanwen % "elpmas_s%"=eulav ,emanwen=eman(maraPtseT.ptxg = pt +)pt(dneppa.maraptset.fles +:0 > )seliftuo.fles(nel fi +]"eman"[]0[seliftuo.fles = emanwen +]"tamrof"[]0[seliftuo.fles = tmfwen +)0=sehsad_mun ,tmfwen=tamrof ,emanwen(ataDtuptuO.ptxg = tuona +emanwen % "s%$ >" = edirrevo_enil_dnammoc.tuona +lanoitisop_si.fles = lanoitisop.tuona +)tuona(dneppa.stuptuot.fles +)emanwen % "elpmas_s%"=eulav ,emanwen=eman(tuptuOtseT.ptxg = pt +)pt(dneppa.maraptset.fles + +aqon # :)fles(LMXekam fed +""" +tpircs wen eht rof repparw loot lmx yxalaG a etaerC +lmthyxalag sesU +...redro tcerroc otni enil dnammoc eht teg ot woH .mmmH +""" +:edirrevo_dnammoc.fles fi +elif gifnoc # edirrevo_dnammoc.fles = edirrevo_dnammoc.lootwen.fles +:esle +lclmx.fles = edirrevo_dnammoc.lootwen.fles +)(snoitatiC.ptxg = etic +)"375stb/scitamrofnioib/3901.01"=eulav ,"iod"=epyt(noitatiC.ptxg = etica +)etica(dneppa.etic +etic = snoitatic.lootwen.fles +"" = txetrefas +:txet_pleh.sgra.fles fi +)(senildaer.)"r" ,txet_pleh.sgra.fles(nepo = txetpleh +)]txetpleh ni x rof )x(epacse_hateehc[(nioj."n\" = txetrefas +:0 == ))(pirts.txetrefas(nel fi +( = txetrefas +"n\esaelp txet pleh htiw dliuber ot )s%( rohtua loot eht ksA" +)liame_resu.sgra.fles( % +) +:htap_tpircs.sgra.fles fi +:0 > )txetrefas(nel fi +!dewolla noitisnart # "n\------n\n\" + txetrefas = txetrefas +]"" > )(pirts.x fi tpircSdecaps.fles ni x rof x[ = rcs +)"n\::tpircSn\n\" ,0(tresni.rcs +:003 > )rcs(nel fi +( = rcs +]001:[rcs +]"...... " ,"deteled ffuts - senil 003> "[ + +]:001-[rcs + +) +)"n\"(dneppa.rcs +)rcs(nioj."n\" + txetrefas = txetrefas +txetrefas = pleh.lootwen.fles +'"}noisrev_loot.sgra.fles{" ohce'f = dnammoc_noisrev.lootwen.fles +)(soidtS.ptxg = dts +)(oidtS.ptxg = 1dts +)1dts(dneppa.dts +dts = soidts.lootwen.fles +)(stnemeriuqeR.ptxg = stnemeriuqer +][ = vneadnoc.fles +:segakcap.sgra.fles fi +:yrt +:)","(tilps.segakcap.sgra.fles ni d rof +enoN = rev +enoN = gkcap +)":" ,"=="(ecalper.d = d +)":" ,"="(ecalper.d = d +:d ni ":" fi +)":"(tilps.d = rev ,gkcap +)(pirts.rev = rev +)(pirts.gkcap = gkcap +:esle +)(pirts.d = gkcap +enoN = rev +:"" == rev fi +enoN = rev +:gkcap fi +(dneppa.stnemeriuqer +)rev ,)(pirts.gkcap ,"egakcap"(tnemeriuqeR.ptxg +) +)d(dneppa.vneadnoc.fles +:noitpecxE tpecxe +(tnirp +,"= esrap tonnac - deilppus gnirts segakcap demroflam ###" +,segakcap.sgra.fles +) +)2(tixe.sys +stnemeriuqer = stnemeriuqer.lootwen.fles +:"0" == ssapmarap.sgra.fles fi +)(marapLMXoNod.fles +:esle +)(marapLMXod.fles +stuptuot.fles = stuptuo.lootwen.fles +stupnit.fles = stupni.lootwen.fles +:htap_tpircs.sgra.fles fi +)(selifgifnoC.ptxg = selifgifnoc +(dneppa.selifgifnoc +))tpircSdepacse.fles(nioj."n\"=txet ,"emnur"=eman(elifgifnoC.ptxg +) +selifgifnoc = selifgifnoc.lootwen.fles +)(stseT.ptxg = stset +)(tseT.ptxg = a_tset +:maraptset.fles ni pt rof +)pt(dneppa.a_tset +)a_tset(dneppa.stset +stset = stset.lootwen.fles +(tnemmoc_dda.lootwen.fles +".yrotcaF looT yxalaG eht gnisu s% ta s% yb detaerC" +))(wonemit ,liame_resu.sgra.fles( % +) +))LRUyrotcaFloot( % "s% :ta tig ni ecruoS"(tnemmoc_dda.lootwen.fles +)(tropxe.lootwen.fles = 0lmxe +detpecca RP litnu dnuora krow yraropmet # )"" ,EXEEKAF(ecalper.0lmxe = lmxe +( fi +edirrevo_tset.fles +stset rof stcejbo lmxl stcepxe ti sa lmxyxalag edisni siht od tonnac # :) +]0[)">stset<"(tilps.lmxe = 1trap +]1[)">stset/<"(tilps.lmxe = 2trap +)2trap ,)edirrevo_tset.fles(nioj."n\" ,1trap( % "s%n\s%n\s%" = dexif +dexif = lmxe +:fx sa )"w" ,eman_loot.fles % "lmx.s%"(nepo htiw +)lmxe(etirw.fx +)"n\"(etirw.fx +meti yrotsih yxalag # + +:)fles(lmydehSetirw fed +"""omenalp rof""" +]0[)"@"(tilps.liame_resu.sgra.fles = resuy +)"lmy.dehs." ,ridtuoloot.fles(nioj.htap.so = emanfy +)"w" ,emanfy(nepo = flmay +{ = tcido +,eman_loot.fles :"eman" +,resuy :"renwo" +,"detcirtsernu" :"epyt" +,csed_loot.sgra.fles :"noitpircsed" +,csed_loot.sgra.fles :"sisponys" +,"slooT detareneG FT" :"yrogetac" +} +)eurT=edocinu_wolla ,flmay ,tcido(pmud.lmay +)(esolc.flmay + +:)fles(looTekam fed +"""ecalp otni selpmas tupni dna slmx etirw""" +:0 == ssapmarap.sgra.fles fi +)(marapLMXoNod.fles +:esle +)(LMXekam.fles +:htap_tpircs.sgra.fles fi +)elifs.fles ,ridtuoloot.fles(nioj.htap.so = emants +:)emants(stsixe.htap.so ton fi +)emants ,elifs.fles(elifypoc.lituhs +eman_loot.fles % "lmx.s%" = laerx +)laerx ,ridtuoloot.fles(nioj.htap.so = tuox +)tuox ,laerx(elifypoc.lituhs +)laerx ,ridper.fles(nioj.htap.so = tuox +)tuox ,laerx(elifypoc.lituhs +:selifni.fles ni p rof +]"eman"[p = htp +)]"emanelifni"[p % "elpmas_s%" ,ridtset.fles(nioj.htap.so = tsed +)tsed ,htp(elifypoc.lituhs +(nioj.htap.so = tsed +)]"tamrof"[p ,]"emanelifni"[p( % "s%.elpmas_s%" ,ridper.fles +) +)tsed ,htp(elifypoc.lituhs +)eman_loot.fles ,sloot_lacol.fles(nioj.htap.so = tsed +)eurT=ko_tsixe_srid ,tsed,ridtuoloot.fles(eertypoc.lituhs + +:)eslaF=liaf_troper ,fles(raTlooTekam fed +"""llabrat eht eraperp dna atad-tset otni stuptuo evom""" +"lmth.troper_tset_omenalp_" = emedulcxe + +:)ofnirat(noitcnuf_edulcxe fed +eman.ofnirat = emanelif +ofnirat esle )emedulcxe(htiwsdne.emanelif fi enoN nruter + +:seliftuo.fles ni p rof +]"eman"[p = emano +)emano % "elpmas_s%" ,ridtset.fles(nioj.htap.so = tsedt +)emano ,ridtset.fles(nioj.htap.so = crs +:)tsedt(elifsi.htap.so ton fi +:)crs(elifsi.htap.so fi +)tsedt ,crs(elifypoc.lituhs +))]'tamrof'[p,emano( % "s%.elpmas.s%" ,ridper.fles(nioj.htap.so = tsed +)tsed ,crs(elifypoc.lituhs +:esle +:liaf_troper fi +(tnirp +".s% nur omenalp retfa ridtset ni dnuof ton s% elif tuptuo - deliaf evah yam looT###" +)ridtset.fles ,tsedt( % +) +)"zg:w" ,htapratwen.fles(nepo.elifrat = ft +(dda.ft +,ridtuoloot.fles=eman +,eman_loot.fles=emancra +,noitcnuf_edulcxe=retlif +) +))"zg.dehsloot_detsetnu_}eman_loot.fles{"f ,ridtuoloot.fles(nioj.htap.so ,htapratwen.fles(ypoc.lituhs +)(esolc.ft + + +:)fles(etadpu_tset_omenalp fed +gnitset rof elbaliava si os tnemeriuqer a si omenalp""" +""" +eman_loot.fles % "lmx.s%" = laerx +(nioj.htap.so = htap_tset_loot +"lmth.troper_tset_omenalp_}eman_loot.fles{"f ,ridper.fles +) +:)golt.fles(stsixe.htap.so fi +)"a" ,golt.fles(nepo = tuot +:esle +)"w" ,golt.fles(nepo = tuot +[ = llc +,"omenalp" +,"tset" +,"tini_otua_adnoc--" +,"sreniatnocoib--" +,"atad_tset--" +,)ridtset.fles(htapsba.htap.so +,"tuptuo_tset--" +,)htap_tset_loot(htapsba.htap.so +,"toor_yxalag--" +,toor_yxalag.sgra.fles +,"atad_tset_etadpu--" +,)laerx(htapsba.htap.so +] +(nur.ssecorpbus = p +,llc +,eslaF=llehs +,ridtuoloot.fles=dwc +,tuot=rredts +,tuot=tuodts +) +)(esolc.tuot +edocnruter.p nruter + + +:) fles(fnocloot_etadpu fed + +:)rtta ,tnerap(ybnerdlihctros fed +))rtta(teg.dlihc :dlihc adbmal=yek ,tnerap(detros = ]:[tnerap + +)'lmx.fnoc_loot_lacol/gifnoc',toor_yxalag.sgra.fles(nioj.htap.so = htapct +)eman_loot.fles % 'lmx.s%' ,eman_loot.fles ,sloot_lacol.fles(nioj.htap.so = eliflmx +)eurT=txet_knalb_evomer(resraPLMX.TE = resrap +)resrap ,htapct(esrap.TE = eert +)(toorteg.eert = toor +eslaF = FTsah +)"noitces"(lladnif.toor = e +:0 > )e(nel fi +eurT = FTsah +]0[e = noitcesFT +:FTsah ton fi +)}"slooT lacoL":"eman" ,"slootlacol":"di"{ ,"noitces"(tnemelE.TE = noitcesFT +!pot eht ta # )noitcesFT ,0(tresni.toor +)"loot"(lladnif.noitcesFT = sloot_ruo +]sloot_ruo ni x rof ]"elif"[birtta.x[ = sloot_fnoc +wen # :sloot_fnoc ni ton eliflmx fi +)}eliflmx :"elif"{ ,"loot" ,noitcesFT(tnemelEbuS.TE +)"elif",noitcesFT(ybnerdlihctros +)eurT=tnirp_ytterp ,htapct(etirw.eert + + + + + + +:)fles(daoLdehs fed +""" +yrotisoper wen etaerc ot dnelboib esu +gnitsixe etadpu ro + +""" +:)golt.fles(stsixe.htap.so fi +)"a" ,golt.fles(nepo = ots +:esle +)"w" ,golt.fles(nepo = ots + +(ecnatsnIdehSlooT.dehsloot = st +,lru_dehsloot.sgra.fles=lru +,yek_ipa_dehsloot.sgra.fles=yek +,eslaF=yfirev +) +)(seirotisoper_teg.seirotisoper.st = soper +]soper ni x rof )"?" ,"eman"(teg.x[ = semanr +]soper ni x rof )"?" ,"di"(teg.x[ = sdir +"sloot detareneg yrotcaFlooT" = tacft +:semanr ni ton eman_loot.fles fi +)(seirogetac_teg.seirogetac.st = tacst +]tacst ni x rof )(pirts.)"?" ,"eman"(teg.x[ = semanc +]tacst ni x rof )"?" ,"di"(teg.x[ = sdic +enoN = DItac +:semanc ni )(pirts.tacft fi +)tacft(xedni.semanc = ic +]ic[sdic = DItac +(yrotisoper_etaerc.seirotisoper.st = ser +,eman_loot.sgra.fles=eman +,csed_loot.sgra.fles % "s%:sisponyS"=sisponys +,csed_loot.sgra.fles=noitpircsed +,"detcirtsernu"=epyt +,lru_dehsloot.sgra.fles=lru_yrotisoper_etomer +,enoN=lru_egapemoh +,DItac=sdi_yrogetac +) +)enoN ,"di"(teg.ser = dit +)"n\}ser{=ser }dit{=dit }eman_loot.sgra.fles{ yrotisoper_etaerc#"f(etirw.ots +:esle +)eman_loot.fles(xedni.semanr = i +]i[sdir = dit +:yrt +(yrotisoper_etadpu.seirotisoper.st = ser +enoN=egassem_timmoc ,htapratwen.fles=htap_llab_rat ,dit=di +) +)"n\}ser{= }di{ di ser etadpu#"f(etirw.ots +:rorrEnoitcennoC tpecxe +(etirw.ots +"n\deliaf daolpu dehs dnelboiB ?tcerroc yek IPA eht dna gninnur dehsloot eht sI #######" +) +)(esolc.ots + +:)fles(daol_yxalag_hpe fed +""" +ti sdaolpu omenalp retfa dehsloot lacol eht morf loot wen eht daol ot siremehpe esu +""" +:)golt.fles(stsixe.htap.so fi +)"a" ,golt.fles(nepo = tuot +:esle +)"w" ,golt.fles(nepo = tuot +[ = llc +,"sloot-dehs" +,"llatsni" +,"g-" +,lru_yxalag.sgra.fles +,"tsetal--" +,"a-" +,yek_ipa_yxalag.sgra.fles +,"eman--" +,eman_loot.fles +,"renwo--" +,"rabuf" +,"dehsloot--" +,lru_dehsloot.sgra.fles +,"lebal_noitces--" +,"yrotcaFlooT" +] +))llc(nioj." " % "n\s%n\gninnur"(etirw.tuot +(nur.ssecorpbus = pbus +,llc +,vneruo.fles=vne +,dwcruo.fles=dwc +,eslaF=llehs +,tuot=rredts +,tuot=tuodts +) +(etirw.tuot +)edocnruter.pbus ,eman_loot.fles( % "n\d% edocter tog - s% dellatsni" +) +)(esolc.tuot +edocnruter.pbus nruter + +:)fles(tset_rekcodoib_omenalp fed +a retfa yppahnu steg dna reniatnoc emas eht ni desu fi seicnedneped skael yltnerruc omenalp""" +039674137-tnemmoceussi#8701/seussi/omenalp/tcejorpyxalag/moc.buhtig//:sptth .nur lufsseccus tsrif + +sdaolnwod detaeper evas ot dellif sehcac htiw omenalp sah reniatnocoib rekcoD + + +""" + +:)"rekcodoib"=resu ,lc ,tuot ,reniatnoc(nurp fed +)resu=resu ,lc(nur_cexe.reniatnoc = golr +)"n\\"(tilps.)golr(rts = lgols +)lgols(nioj."n\" = gols +)"n\}lc{ morf }gols{ golr tog ##"f(etirw.tuot + +:)golt.fles(stsixe.htap.so fi +)"a" ,golt.fles(nepo = tuot +:esle +)"w" ,golt.fles(nepo = tuot +"reniatnocoib-omenalp/2rabuf/oi.yauq" = egamiomenalp +eman_loot.fles % "lmx.s%" = laerx +"lmth.troper_tset_omenalp_}eman_loot.fles{"f = emanper +)emanper ,ridper.fles(nioj.htap.so = htap_pertsetp +)(vne_morf.rekcod = tneilc +)(etaerc.semulov.tneilc = lovt +eman.lovt = emanlovt +"tsetp/yrotcafloot/" = ridtsed +)emanper ,ridtsed(nioj.htap.so = permi +peels htiw nepo ti peek os gninnur reniatnoc eht peek ot deen # +enod era ew nehw ti yortsed dna pots lliw # +(nur.sreniatnoc.tneilc = reniatnoc +,egamiomenalp +,"m021 peels" +,eurT=hcated +,"rekcodoib"=resu +,}}"wr" :"edom" ,"yrotcafloot/" :"dnib"{ :"}emanlovt{"f{=semulov +) +"}ridtsed{ p- ridkm"f = lc +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +(: reniatnoc rekcodoib a no toor teg ot si ti drah woh s'taht # +"*/}ridtsed{ fr- mr"f = lc +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +)laerx ,"tuoft" ,ridtsed(nioj.htap.so = htaptsetp +)reniatnoc ,ridtsed ,ridtuoloot.fles(reniatnoc_ot_ypoc.fles +"yrotcafloot/ rekcodoib R- nwohc" = lc +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +)"}ridtsed{ al- sl"f(nur_cexe.reniatnoc = _ +"}htaptsetp{ lartnec-yxalag/rekcodoib/emoh/ toor_yxalag-- atad-tset/tuoft/}ridtsed{ atad_tset-- punaelc_on-- atad_tset_etadpu-- }permi{ tuptuo_tset-- tset omenalp"f = lctsetp +:yrt +)lctsetp(nur_cexe.reniatnoc = _ +yrotcerid atad-tset eht setadpu tub gnissim stuptuo tset esuaceb sliaf # +:noitpecxE tpecxe +]0[)(ofni_cxe.sys = e +)"n\}lctsetp{ morf }e{ :rorre ####"f(etirw.tuot +"}htaptsetp{ lartnec-yxalag/rekcodoib/emoh/ toor_yxalag-- atad-tset/tuoft/}ridtsed{ atad_tset-- punaelc_on-- }permi{ tuptuo_tset-- tset omenalp"f = lc +:yrt +)lc ,tuot ,reniatnoc(nurp +:noitpecxE tpecxe +]0[)(ofni_cxe.sys = e +)"n\}lctsetp{ morf }e{ :rorre ####"f(etirw.tuot +)"."=rid ,"pmetft"=xiferp ,enoN=xiffus(pmetdkm.elifpmet = stuotset +)reniatnoc ,stuotset ,ridtsed(reniatnoc_morf_ypoc.fles +)"tsetp" ,stuotset(nioj.htap.so = crs +:)crs(ridsi.htap.so fi +)eurT=ko_tsixe_srid ,"." ,crs(eertypoc.lituhs +emanper = crs +:)emanper(elifsi.htap.so fi +)htap_pertsetp ,crs(elifypoc.lituhs +:esle +)"n\}crs{ ni eertypoc.lituhs ot nur morf tuptuo oN"f(etirw.tuot +)(esolc.tuot +)(pots.reniatnoc +)(evomer.reniatnoc +)(evomer.lovt +gniggubed rof evael # )stuotset(eertmr.lituhs + + +:)fles(nur fed # +""" # +!epip eht llif ot ton hguone llams eb tsum stpircs # +""" # +:]'hs','hsab'[ ni reterpretni.stpo.fles dna laicepShsabtaert.fles fi # +)(hsaBnur.fles = lavter # +:esle # +:rid_tuptuo.stpo.fles fi # +)'w',gole.fles(nepo = ets # +)'w',golt.fles(nepo = ots # +))lc.fles(nioj.' ' % 'n\s% = enil dnammoc detareneg yrotcaflooT ##'(etirw.ots # +)(hsulf.ots # +)rid_tuptuo.stpo.fles=dwc,EPIP.ssecorpbus=nidts,ets=rredts,ots=tuodts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +:esle # +)EPIP.ssecorpbus=nidts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +)tpircs.fles(etirw.nidts.p # +)(esolc.nidts.p # +)(tiaw.p = lavter # +:rid_tuptuo.stpo.fles fi # +)(esolc.ots # +)(esolc.ets # +)(daer.)'r',gole.fles(nepo = rre # +melborp # :rre dna 0 >< lavter fi # +)rre,lavter( % 's%n\:htiw denruter d% edoc rorre ##' ,rredts.sys >> tnirp # +:LMTH_ekam.stpo.fles fi # +)(lmtHekam.fles # +lavter nruter # + +:)fles(hsaBnur fed # +""" # +elifs.fles esu os hsab rof - esu tonnac # +""" # +:rid_tuptuo.stpo.fles fi # +)lc.fles(nioj.' ' % 'n\s% = enil dnammoc detareneg yrotcaflooT ##' = s # +)'w',golt.fles(nepo = ots # +)s(etirw.ots # +)(hsulf.ots # +)rid_tuptuo.stpo.fles=dwc,ots=rredts,ots=tuodts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +:esle # +)eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +)(tiaw.p = lavter # +:rid_tuptuo.stpo.fles fi # +)(esolc.ots # +:LMTH_ekam.stpo.fles fi # +)(lmtHekam.fles # +lavter nruter # + +:)tsil_ped ,fles(vne_adnoc_ekam fed # +""" # +41.4.0=lmxyxalag,0.71.0=dnelboib hsah-dellum $yxalag/love/:trgwen-ssor@yxalag )vnev( # +500a8f50602aa9ddddf3b34236190956b800b0d1:983b81d3ac50b5d66d20e4deb0d3c51e59383473-2v-dellum # + +lebab diortsa 3.71.0=ypics 9.3=nohtyp vneym n- etaerc adnoc # + + +""" # +)(tros.tsil_ped # +)tsil_ped(nioj.'-' = eman_vne.fles # ++ lclmx.fles ni e rof # + +:xiffuslcx.fles ni e rof # +]]"emanelifni"[p % "s%$ <" ,]"emanelifni"[p ,"999"[ = emdneppax # # +:esle # +]"" ,]"emanelifni"[p % "s%$" ,]"LC"[p[ = emdneppax # +)emdneppax(dneppa.xiffuslcx # +:)golt.fles(stsixe.htap.so fi # +)"a" ,golt.fles(nepo = tuot # +:esle # +)"w" ,golt.fles(nepo = tuot # +])tsil_ped(nioj.' ' ,eman_vne.fles ,"n-" ,"etaerc" ,"adnoc"[ = ilc # +(nur.ssecorpbus = p # +,llc # +,eslaF=llehs # +,ridtuoloot.fles=dwc # +,tuot=rredts # +,tuot=tuodts # +) # +]" && " ,eman_vne.fles ,"etavitca" ,"adnoc"[ = ilc # +)dmc_nur(dneppa.ilc # +)(esolc.tuot # + +:)(niam fed +""" +.repparw yxalaG a si sihT +lmx.loot esoprup laiceps a yb dellac eb ot stcepxe tI + +""" +)(resraPtnemugrA.esrapgra = resrap +tnemugra_dda.resrap = a +)enoN=tluafed ,"htap_tpircs--"(a +)enoN=tluafed ,"tset_yrotsih--"(a +)enoN=tluafed ,"xiffus_resu_lc--"(a +)enoN=tluafed ,"exesys--"(a +)enoN=tluafed ,"segakcap--"(a +)"lootwen"=tluafed ,"eman_loot--"(a +)enoN=tluafed ,"rid_loot--"(a +)"dneppa"=noitca ,][=tluafed ,"selif_tupni--"(a +)"dneppa"=noitca ,][=tluafed ,"selif_tuptuo--"(a +)"nwonknU"=tluafed ,"liame_resu--"(a +)enoN=tluafed ,"resu_dab--"(a +)enoN=tluafed ,"txet_pleh--"(a +)enoN=tluafed ,"csed_loot--"(a +)"10.0"=tluafed ,"noisrev_loot--"(a +)enoN=tluafed ,"snoitatic--"(a +)enoN=tluafed ,"edirrevo_dnammoc--"(a +)enoN=tluafed ,"edirrevo_tset--"(a +)][=tluafed ,"dneppa"=noitca ,"sretemarap_lanoitidda--"(a +)][=tluafed ,"dneppa"=noitca ,"sretemarap_txettceles--"(a +)eslaF=tluafed ,"eurt_erots"=noitca ,"sretemarap_lanoitidda_tide--"(a +)"lanoitisop"=tluafed ,"ssapmarap--"(a +)"tuoft/."=tluafed ,"tuoft--"(a +)"lartnec-yxalag/"=tluafed ,"toor_yxalag--"(a +)"vnev_yxalag/"=tluafed ,"vnev_yxalag--"(a +)][=tluafed ,"dneppa"=noitca ,"noitcelloc--"(a +)"eurt_erots"=noitca ,eslaF=tluafed ,"stset_edulcni--"(a +)eslaF=tluafed ,"eurt_erots" = noitca ,"galf_llatsni--"(a +)"eurt_erots"=noitca ,eurT=tluafed ,"ylno_nimda--"(a +)enoN=tluafed ,"tuo_loot_detsetnu--"(a +__rid_toor__$ ot evitaler # )"sloot"=tluafed ,"sloot_lacol--"(a +__rid_toor__$ ot evitaler # )"lmx.fnoc_loot/gifnoc"=tluafed ,"htap_fnoc_loot--"(a +)(sgra_esrap.resrap = sgra +:ylno_nimda.sgra fi +( ,resu_dab.sgra ton tressa +\ yxalaG litnu loot siht esu ot dezirohtua TON si s% :DESIROHTUANU' +'elif noitarugifnoc yxalaG lmy.yxalag eht ni "sresu_nimda" ot s% sdda nimda +)resu_dab.sgra ,resu_dab.sgra( % +) +".eno ylppus esaelP .eman loot a tuohtiw loot a dliub tonnac yrotcaFlooT sihT ##" ,eman_loot.sgra tressa +)sgra(yrotcaF_looT = ft +)(lmydehSetirw.ft +)(looTekam.ft +)(etadpu_tset_omenalp.ft +)(raTlooTekam.ft +)(fnocloot_etadpu.ft + + +:"__niam__" == __eman__ fi +)(niam
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/seqtk_telo/seqtk_telo.seqtk=1.4.txt Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1 @@ +seqtk $infa > $out_bed 2> $out_count
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/seqtk_telo/seqtk_telo.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,32 @@ +<tool name="seqtk_telo" id="seqtk_telo" version="1.4" profile="22.05"> + <!--Source in git at: https://github.com/fubar2/galaxy_tf_overlay--> + <!--Created by toolfactory@galaxy.org at 09/12/2023 14:04:09 using the Galaxy Tool Factory.--> + <description></description> + <requirements> + <requirement version="1.4" type="package">seqtk</requirement> + </requirements> + <version_command><![CDATA[echo "1.4"]]></version_command> + <command><![CDATA[bash $runme]]></command> + <configfiles> + <configfile name="runme"><![CDATA[seqtk telo $infa > $out_bed ]]></configfile> + </configfiles> + <inputs> + <param name="infa" type="data" optional="false" label="Fasta input for telomere finding" help="" format="fasta" multiple="false"/> + </inputs> + <outputs> + <data name="out_bed" format="bed" label="seqtk_telo on $infa.element_identifier" hidden="false"/> + </outputs> + <tests> + <test> + <output name="out_bed" value="out_bed_sample" compare="diff" lines_diff="0"/> + <param name="infa" value="infa_sample"/> + </test> + </tests> + <help><![CDATA[ + **What it Does** + ]]></help> + <citations> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/seqtk_telo/test-data/infa_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,163 @@ +>test +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +GCACTCGCCGCGAGGGTTGCCGGGACGGGCCCAAGATGGCTGAGCGCCTT +GGTTCCGCTTCTGCCTGCCGCGCAGAGCCCCATTCATTGCCTTGCTGCTA +AGTGGCGCCGCGTAGTGCCAGTAGGCTCCAAGTCTTCAGGGTCTGTCCCA +TCGGGCAGGAAGCCGTCATGGCAACCCTGGAAAAGCTGATGAAGGCTTTC +GAGTCGCTCAAGTCGTTTCAGCAGCAACAGCAGCAGCAGCCACCGCCGCA +GGCGCCGCCGCCACCGCCGCCGCCGCCTCCGCCTCAACCCCCTCAGCCGC +CGCCTCAGGGGCAGCCGCCGCCGCCACCACCGCCGCTGCCAGGTCCGGCA +GAGGAACCGCTGCACCGACCGTGAGTCCGGGCGCCGCAGCTCCCGCCCGG +GCCCCGCGCCCCTGGCCTGCGTGCTGGGCATGGCCAACACTGTTCCCTGT +CCAGAGGGTCGCGGTACCTCCCTGAGGCCAGGCTTTCCCGGCCCGGGCCC +TCGTCTTGCGGGGTCTCTGGCCTCCCTCAGAGGAGACAGAGCCGGGTCAG +GCCAGCCAGGGACTCGCTGAGGGGCGTCACGACTCCAGTGCCTTCGCCGT +TCCCAGTTTGCGAAGTTAGGGAACGAACTTGTTTCTCTCTTCTGGAGAAA +CTGGGGCGGTGGCGCACATGACTGTTGTGAAGAGAACTTGGAGAGGCAGA +GATCTCTAGGGTTACCTCCTCATCAGGCCTAAGAGCTGGGAGTGCAGGAC +AGCGTGAGAGATGTGCGGGTAGTGGATGACATAATGCTTTTAGGAGGTCT +CGGCGGGAGTGCTGAGGGCGGGGGAGTGTGAACGCATCCAATGGGATATT +CTTTTTCCAAGTGACACTTGAAGCAGCCTGTGACTCGAGGCACTTCGTAC +TCTCCTGGCGTTTCATTTAGTTTGTGGTGTAGTGTAGTTAAACCAGGTTT +TAAGCATAGCCAGAGAGGTGTGCTTCTGTGTGTCTGCAGGCAGTTGGATG +AGTTGTATTTGTCAAGTACATGGTGAGTTACTTAGGTGTGATTATTAATA +AAAAACTATATGTGTGCATATATATGAAAGAGTCGACTTATACTTAACTG +CCTATCGATTTTTTGTTCTATATAAAACGGATACATTGGTGGTGCTCAGT +TTTCACCGGGGAATGAATTTTACTAGTGTTGCAGACAGGCTTGTTTTAGA +ACATAGGCCACTCTGACTCTGACTTTGTGCCAGTAAAAGTTCCTGTTTAG +TTCTTTGCTGACATCTTATAGATCTTTGGAAGCTAGCTGCTTGTGACTGG +AGAGAATATTGAAACAGAAGAGAGACCATGAGTCACAGTGCTCTAAGAGA +AAAGAGACGCTCAAAACATTTCCTGGAAATCCATGCTGAGTGTTGAGCCC +TGTGCTCTCTTGCAGCTCAGTCCTTTCTCTCAACTCTGGGCATTTTATTT +CTAATCTGGATTTGTATAATTAATAAGGAGAACTTTTGGGAACAACCTAC +TAAAGAATGTCATCATTAAAACTCACTTAGAAAATAAGTGTTCTGGTGAT +ATCATTGAGCTATGTTCCCAGTCCTGAGAGTTTGTTTTTTTTTTTTTTTT +TAAATAAAGATTTGGGGAGAAAAGGTGGCTTACTTGATAGAACAAAATAT +AGGAATAAAATTTCCTTCTATAAGGTGAAAAGTGTGAATAGAAAACTTCT +TATCCTCTAGATAAGTAGTTTCTTTTTGCTTTTGAGAGTCTCACTATGTA +ACTCTTGACCTGAACTCAGAGAGATCCATCCTCCTGCCTCTGCCTCCTCT +CTCTGGGATTAAAGGCATGTGGCACCATGCTGGGCTGTCCAAGTATGCCA +CAGACCCTCTAGGTCCCTGGTCTTCGAGGAACGGGATTTCTTAGGCAGAT +GGGTAAGGAGTCGGATGAAAATGACAATCAGCCACACACAAGAGAGGTGT +TGAATCTGAATGTAATGTTCTGGTTGAGCTTCAGACTTATATAACAACGA +ATTATCAGAGGATACAAATCACAAAAAGACAAGATACACTGAAATTCACC +AGTTACAGCAGAAAGGAATTTGCAGGGACTAATTAAATGTTTACATTAGG +GATAACAAGCCCTGCCTAGGATCAGCCTAATGCCAGGCAAGAATTTCACA +CTTTAAGGTTAAAAGCATCAGGGGGTTGTTAACTCTTGACAGGCCTTAAG +AGTAATGTGCTATCACTGAGCTCTAAATTCTTAGGTCTAGTAAAACTTAT +CCTGTCTGGAGAGTTCCCCCTTATCAGGGTAGTATATCAACTTATACTTG +ACATGGAATGAAGCCTGTAGTAAAACATTTCTATCTCAGTGAGACTTTTA +GTCTCTATCTGTAAACAGCTGAGTAAAATGGCAAGTGCTTAATTGTTTAC +TGAATGGGTTAAGCTCCTTGCTGCTATCTGGAATCTAAGAACACTGGGGA +AAGGCTTTAGCTATGTTAGAATACAATATTAAAAGGCATTTACTATAAGG +TGATGCTTAATAGAGTGCACGTGAATCTATACACTAGATTAATGTGGTGG +AAATTTGAATATAATGGGTTAGGGAAAGAGATGCCATAACTCTGGGAGGA +AAATTTCCCTGGACTCTTATCCTCGTGAAACAGCTTCCAGGCTTTTCGCC +TGACAAACCGATCCAAACTGGAGAGTTGGCTTTCGCCAGAATATCCAGGA +GGAGAGTCCTAGAAATTCATTTCTCATGAGCAGCTTTTTGGCATTTTTGC +CTCACAAGCTGACTCCACCAGAGTACCCTGACACAAGTATTGTCTAGTTA +TTTTGATTATTACCATGACTCTGCCTCTGGGTGAGAGGAATTGTGGAAGT +TTACATATTCCCCATATCTTCTATAAACCTCTGTGTGTGTGTGTGTGTGT +GTGTGTGTGTGTGTGTGTGTGTGTATGAGGGAGAGAGAGGGAGAGAGAGA +GAGGGAGGGAGGAAGAGAGAGAGAGAGATTGTTCTGTGCCTGCTTCGAAC +ACAAATTAGTTTGCAAAAGTAATTCATTAACATGATACAGTCCCAAAGAT +AAAAATGGTTAAATAATGAAAACATCTCCCTCCCCATTTTCCTAACTTTG +TACCCAGGAGCAAGCTCTGTTACACTTCATTTGTCCTTCCAGATAAAATT +TGGGCATATGTTAGGACAGAATTTTAAATTATTTACAAACAAAAGTATTT +TGGAACAAAAGCTTTTAAAAGCTTTTATTTTAATAAAATAACTTGTTACT +ACACTGTATATAACTAACTAACATTTTCCAAAATTAGCTCCATTAGCATC +TATCTCATATTTCTATGTACTTTGCTGTTGAAAAACCAAGTGTTCATTAA +TAATAAGTAACAAACTCACTGCTTGGAAGCTTTGATTTTTGGCATTTTGT +CCACTTGACTCAGTTAAAAGTCCTTTTTTTCGAAATGAGAACAGCCAAAA +CAGTTTTAGAATGAGTCTGTTCTGCTTTTGTGACTCTCATTGTGTTCTGT +AGAACCAGTGTCACAGCCATATGTGGGCCTCTGTTGAAGTAGCTGAGAAC +TTGTTCTCTGCTCTGCTAGCTGCTGTCGATCTGATAGGCCTTGAACAGTT +GACATTCACCCTTAATAGTCCTCATTAGTCTTCCTGAGCATAGTCATTCA +TTTATCAATATTTGCTGATCATCTCCTATGTGCCTAGCATTGTTCTAGTT +GCAGGTTTTAGCAGGGAACAAAGTCATGTCTCATGAAGCTAAAATTCTTG +GGAGAGACATAGACAGTAAGCAGAATAGTTTGTTCATAGTGAGTGATGAG +GCGCATGCAGTAAAGTAGGGAAGGGGATTAGGAAATGCCAGGGCTTGACA +TGTTTTAGACAGGGTGTTTAAATAATATCTGCTTAGTTGAAGGCTTATTT +TTGAATAAATATCTGAAGAGTCAGAAATCTACCAGGAGGGTGTATGGAAG +AGGAGTATTCCTGCAAGGGGAAGTTGTCAAAGGCTTTCCTGTGTGGGGAT +TAGTGATGTCATGTTTTTGCTGGATGAAATGAGTGACGGTAAGAGTTGTA +GTGGGGGTGAAGCAAAGGGTTGAGGGAGGCTTCATTGGTGTTATCAGTTA +CTGCATTTATCTCCAAATAGAGAACGTAGCAATGAAAGCTACAGAGAACG +GGAAAGGTGAGGATTTATTCTAAGACAAAATAAGTGTAGGAAGTTTAACA +ATTAGATCAGGAGCACAGACTCCAAGTCTAAGTCTTCATTCTTGCACATT +TTTTAAAAATTTTGTTATGTGTTCTGGATACTATTTCCTTATGAGATATA +AGTTTAAAAGCCTTTCTGTGGATTGCCTTGCCTTTGTTGTTGTTGTTTGT +TTTGTTTTGTTTTGTTGAGACAGGTCTCTCTATGTAGCCTTGACTGTCCT +GAAAATCACTCTGTAGACCAGGCTGGCCTGGAACTCAGAGATCTGCCTGC +TTCTGCTTTTCAAGTGCTGATATTAAATGTATGTGCCACCACTGCCAGGC +TAAGATTGTTCTTTCAATTTCTTTTTTTGTTTTCTTTTGAGATCAAAGTT +TGCTATGTACTTTTGGCTGGCCTGGTATATTGTGTAGTCTAAGTTGGCTT +CAAATCTTCATGGCACAGATTCCCAAGTACTGGGACCATAGGTATGGCCC +ATCACAGTGGGGGGTTGGGGGGGCCAGTACATCTATCTCTTGAATGGTGT +GGAGTGTATATATGTGTTAGGGGTTTGCAGAGGCCAAAAGAATATTGAGT +GTCTTCCTCTATTGCTCGCCACTTCTCTGAATAAACCTAAAGTTACCAAT +GGATTTCTAGTAAGCTGACTGACCAGCAAATATTGGGGATCTGTCTGTCC +CTGTTCACCATAGTGAGGTTACAGACGTGAATAACCACACCCAGTTTTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA +CCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAACCCTAA
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tacrev/tacrev.bash.txt Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,3 @@ +#raw +tac | rev +#end raw
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tacrev/tacrev.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,37 @@ +<tool name="tacrev" id="tacrev" version="0.01" profile="22.05"> + <!--Source in git at: https://github.com/fubar2/galaxy_tf_overlay--> + <!--Created by toolfactory@galaxy.org at 05/02/2024 14:13:16 using the Galaxy Tool Factory.--> + <description></description> + <requirements/> + <version_command><![CDATA[echo "0.01"]]></version_command> + <command><![CDATA[bash +'$runme' +< +$Input_text_file_to_be_reversed +> +$tacrev_reversed_output]]></command> + <configfiles> + <configfile name="runme"><![CDATA[#raw +tac | rev +#end raw]]></configfile> + </configfiles> + <inputs> + <param name="Input_text_file_to_be_reversed" type="data" optional="false" label="Input text file to be reversed" help="" format="txt" multiple="false"/> + </inputs> + <outputs> + <data name="tacrev_reversed_output" format="txt" hidden="false"/> + </outputs> + <tests> + <test> + <param name="Input_text_file_to_be_reversed" value="Input_text_file_to_be_reversed_sample"/> + <output name="tacrev_reversed_output" value="tacrev_reversed_output_sample"/> + </test> + </tests> + <help><![CDATA[ + **What it Does** + ]]></help> + <citations> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tacrev/tacrev_reversed_output_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1210 @@ +)(niam +:"__niam__" == __eman__ fi + + +)(fnocloot_etadpu.ft +)(raTlooTekam.ft +)(etadpu_tset_omenalp.ft +)(looTekam.ft +)(lmydehSetirw.ft +)sgra(yrotcaF_looT = ft +".eno ylppus esaelP .eman loot a tuohtiw loot a dliub tonnac yrotcaFlooT sihT ##" ,eman_loot.sgra tressa +) +)resu_dab.sgra ,resu_dab.sgra( % +'elif noitarugifnoc yxalaG lmy.yxalag eht ni "sresu_nimda" ot s% sdda nimda +\ yxalaG litnu loot siht esu ot dezirohtua TON si s% :DESIROHTUANU' +( ,resu_dab.sgra ton tressa +:ylno_nimda.sgra fi +)(sgra_esrap.resrap = sgra +__rid_toor__$ ot evitaler # )"lmx.fnoc_loot/gifnoc"=tluafed ,"htap_fnoc_loot--"(a +__rid_toor__$ ot evitaler # )"sloot"=tluafed ,"sloot_lacol--"(a +)enoN=tluafed ,"tuo_loot_detsetnu--"(a +)"eurt_erots"=noitca ,eurT=tluafed ,"ylno_nimda--"(a +)eslaF=tluafed ,"eurt_erots" = noitca ,"galf_llatsni--"(a +)"eurt_erots"=noitca ,eslaF=tluafed ,"stset_edulcni--"(a +)][=tluafed ,"dneppa"=noitca ,"noitcelloc--"(a +)"vnev_yxalag/"=tluafed ,"vnev_yxalag--"(a +)"lartnec-yxalag/"=tluafed ,"toor_yxalag--"(a +)"tuoft/."=tluafed ,"tuoft--"(a +)"lanoitisop"=tluafed ,"ssapmarap--"(a +)eslaF=tluafed ,"eurt_erots"=noitca ,"sretemarap_lanoitidda_tide--"(a +)][=tluafed ,"dneppa"=noitca ,"sretemarap_txettceles--"(a +)][=tluafed ,"dneppa"=noitca ,"sretemarap_lanoitidda--"(a +)enoN=tluafed ,"edirrevo_tset--"(a +)enoN=tluafed ,"edirrevo_dnammoc--"(a +)enoN=tluafed ,"snoitatic--"(a +)"10.0"=tluafed ,"noisrev_loot--"(a +)enoN=tluafed ,"csed_loot--"(a +)enoN=tluafed ,"txet_pleh--"(a +)enoN=tluafed ,"resu_dab--"(a +)"nwonknU"=tluafed ,"liame_resu--"(a +)"dneppa"=noitca ,][=tluafed ,"selif_tuptuo--"(a +)"dneppa"=noitca ,][=tluafed ,"selif_tupni--"(a +)enoN=tluafed ,"rid_loot--"(a +)"lootwen"=tluafed ,"eman_loot--"(a +)enoN=tluafed ,"segakcap--"(a +)enoN=tluafed ,"exesys--"(a +)enoN=tluafed ,"xiffus_resu_lc--"(a +)enoN=tluafed ,"tset_yrotsih--"(a +)enoN=tluafed ,"htap_tpircs--"(a +tnemugra_dda.resrap = a +)(resraPtnemugrA.esrapgra = resrap +""" + +lmx.loot esoprup laiceps a yb dellac eb ot stcepxe tI +.repparw yxalaG a si sihT +""" +:)(niam fed + +)(esolc.tuot # +)dmc_nur(dneppa.ilc # +]" && " ,eman_vne.fles ,"etavitca" ,"adnoc"[ = ilc # +) # +,tuot=tuodts # +,tuot=rredts # +,ridtuoloot.fles=dwc # +,eslaF=llehs # +,llc # +(nur.ssecorpbus = p # +])tsil_ped(nioj.' ' ,eman_vne.fles ,"n-" ,"etaerc" ,"adnoc"[ = ilc # +)"w" ,golt.fles(nepo = tuot # +:esle # +)"a" ,golt.fles(nepo = tuot # +:)golt.fles(stsixe.htap.so fi # +)emdneppax(dneppa.xiffuslcx # +]"" ,]"emanelifni"[p % "s%$" ,]"LC"[p[ = emdneppax # +:esle # +]]"emanelifni"[p % "s%$ <" ,]"emanelifni"[p ,"999"[ = emdneppax # # +:xiffuslcx.fles ni e rof # + ++ lclmx.fles ni e rof # +)tsil_ped(nioj.'-' = eman_vne.fles # +)(tros.tsil_ped # +""" # + + +lebab diortsa 3.71.0=ypics 9.3=nohtyp vneym n- etaerc adnoc # + +500a8f50602aa9ddddf3b34236190956b800b0d1:983b81d3ac50b5d66d20e4deb0d3c51e59383473-2v-dellum # +41.4.0=lmxyxalag,0.71.0=dnelboib hsah-dellum $yxalag/love/:trgwen-ssor@yxalag )vnev( # +""" # +:)tsil_ped ,fles(vne_adnoc_ekam fed # + +lavter nruter # +)(lmtHekam.fles # +:LMTH_ekam.stpo.fles fi # +)(esolc.ots # +:rid_tuptuo.stpo.fles fi # +)(tiaw.p = lavter # +)eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +:esle # +)rid_tuptuo.stpo.fles=dwc,ots=rredts,ots=tuodts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +)(hsulf.ots # +)s(etirw.ots # +)'w',golt.fles(nepo = ots # +)lc.fles(nioj.' ' % 'n\s% = enil dnammoc detareneg yrotcaflooT ##' = s # +:rid_tuptuo.stpo.fles fi # +""" # +elifs.fles esu os hsab rof - esu tonnac # +""" # +:)fles(hsaBnur fed # + +lavter nruter # +)(lmtHekam.fles # +:LMTH_ekam.stpo.fles fi # +)rre,lavter( % 's%n\:htiw denruter d% edoc rorre ##' ,rredts.sys >> tnirp # +melborp # :rre dna 0 >< lavter fi # +)(daer.)'r',gole.fles(nepo = rre # +)(esolc.ets # +)(esolc.ots # +:rid_tuptuo.stpo.fles fi # +)(tiaw.p = lavter # +)(esolc.nidts.p # +)tpircs.fles(etirw.nidts.p # +)EPIP.ssecorpbus=nidts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +:esle # +)rid_tuptuo.stpo.fles=dwc,EPIP.ssecorpbus=nidts,ets=rredts,ots=tuodts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +)(hsulf.ots # +))lc.fles(nioj.' ' % 'n\s% = enil dnammoc detareneg yrotcaflooT ##'(etirw.ots # +)'w',golt.fles(nepo = ots # +)'w',gole.fles(nepo = ets # +:rid_tuptuo.stpo.fles fi # +:esle # +)(hsaBnur.fles = lavter # +:]'hs','hsab'[ ni reterpretni.stpo.fles dna laicepShsabtaert.fles fi # +""" # +!epip eht llif ot ton hguone llams eb tsum stpircs # +""" # +:)fles(nur fed # + + +gniggubed rof evael # )stuotset(eertmr.lituhs +)(evomer.lovt +)(evomer.reniatnoc +)(pots.reniatnoc +)(esolc.tuot +)"n\}crs{ ni eertypoc.lituhs ot nur morf tuptuo oN"f(etirw.tuot +:esle +)htap_pertsetp ,crs(elifypoc.lituhs +:)emanper(elifsi.htap.so fi +emanper = crs +)eurT=ko_tsixe_srid ,"." ,crs(eertypoc.lituhs +:)crs(ridsi.htap.so fi +)"tsetp" ,stuotset(nioj.htap.so = crs +)reniatnoc ,stuotset ,ridtsed(reniatnoc_morf_ypoc.fles +)"."=rid ,"pmetft"=xiferp ,enoN=xiffus(pmetdkm.elifpmet = stuotset +)"n\}lctsetp{ morf }e{ :rorre ####"f(etirw.tuot +]0[)(ofni_cxe.sys = e +:noitpecxE tpecxe +)lc ,tuot ,reniatnoc(nurp +:yrt +"}htaptsetp{ lartnec-yxalag/rekcodoib/emoh/ toor_yxalag-- atad-tset/tuoft/}ridtsed{ atad_tset-- punaelc_on-- }permi{ tuptuo_tset-- tset omenalp"f = lc +)"n\}lctsetp{ morf }e{ :rorre ####"f(etirw.tuot +]0[)(ofni_cxe.sys = e +:noitpecxE tpecxe +yrotcerid atad-tset eht setadpu tub gnissim stuptuo tset esuaceb sliaf # +)lctsetp(nur_cexe.reniatnoc = _ +:yrt +"}htaptsetp{ lartnec-yxalag/rekcodoib/emoh/ toor_yxalag-- atad-tset/tuoft/}ridtsed{ atad_tset-- punaelc_on-- atad_tset_etadpu-- }permi{ tuptuo_tset-- tset omenalp"f = lctsetp +)"}ridtsed{ al- sl"f(nur_cexe.reniatnoc = _ +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +"yrotcafloot/ rekcodoib R- nwohc" = lc +)reniatnoc ,ridtsed ,ridtuoloot.fles(reniatnoc_ot_ypoc.fles +)laerx ,"tuoft" ,ridtsed(nioj.htap.so = htaptsetp +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +"*/}ridtsed{ fr- mr"f = lc +(: reniatnoc rekcodoib a no toor teg ot si ti drah woh s'taht # +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +"}ridtsed{ p- ridkm"f = lc +) +,}}"wr" :"edom" ,"yrotcafloot/" :"dnib"{ :"}emanlovt{"f{=semulov +,"rekcodoib"=resu +,eurT=hcated +,"m021 peels" +,egamiomenalp +(nur.sreniatnoc.tneilc = reniatnoc +enod era ew nehw ti yortsed dna pots lliw # +peels htiw nepo ti peek os gninnur reniatnoc eht peek ot deen # +)emanper ,ridtsed(nioj.htap.so = permi +"tsetp/yrotcafloot/" = ridtsed +eman.lovt = emanlovt +)(etaerc.semulov.tneilc = lovt +)(vne_morf.rekcod = tneilc +)emanper ,ridper.fles(nioj.htap.so = htap_pertsetp +"lmth.troper_tset_omenalp_}eman_loot.fles{"f = emanper +eman_loot.fles % "lmx.s%" = laerx +"reniatnocoib-omenalp/2rabuf/oi.yauq" = egamiomenalp +)"w" ,golt.fles(nepo = tuot +:esle +)"a" ,golt.fles(nepo = tuot +:)golt.fles(stsixe.htap.so fi + +)"n\}lc{ morf }gols{ golr tog ##"f(etirw.tuot +)lgols(nioj."n\" = gols +)"n\\"(tilps.)golr(rts = lgols +)resu=resu ,lc(nur_cexe.reniatnoc = golr +:)"rekcodoib"=resu ,lc ,tuot ,reniatnoc(nurp fed + +""" + + +sdaolnwod detaeper evas ot dellif sehcac htiw omenalp sah reniatnocoib rekcoD + +039674137-tnemmoceussi#8701/seussi/omenalp/tcejorpyxalag/moc.buhtig//:sptth .nur lufsseccus tsrif +a retfa yppahnu steg dna reniatnoc emas eht ni desu fi seicnedneped skael yltnerruc omenalp""" +:)fles(tset_rekcodoib_omenalp fed + +edocnruter.pbus nruter +)(esolc.tuot +) +)edocnruter.pbus ,eman_loot.fles( % "n\d% edocter tog - s% dellatsni" +(etirw.tuot +) +,tuot=tuodts +,tuot=rredts +,eslaF=llehs +,dwcruo.fles=dwc +,vneruo.fles=vne +,llc +(nur.ssecorpbus = pbus +))llc(nioj." " % "n\s%n\gninnur"(etirw.tuot +] +,"yrotcaFlooT" +,"lebal_noitces--" +,lru_dehsloot.sgra.fles +,"dehsloot--" +,"rabuf" +,"renwo--" +,eman_loot.fles +,"eman--" +,yek_ipa_yxalag.sgra.fles +,"a-" +,"tsetal--" +,lru_yxalag.sgra.fles +,"g-" +,"llatsni" +,"sloot-dehs" +[ = llc +)"w" ,golt.fles(nepo = tuot +:esle +)"a" ,golt.fles(nepo = tuot +:)golt.fles(stsixe.htap.so fi +""" +ti sdaolpu omenalp retfa dehsloot lacol eht morf loot wen eht daol ot siremehpe esu +""" +:)fles(daol_yxalag_hpe fed + +)(esolc.ots +) +"n\deliaf daolpu dehs dnelboiB ?tcerroc yek IPA eht dna gninnur dehsloot eht sI #######" +(etirw.ots +:rorrEnoitcennoC tpecxe +)"n\}ser{= }di{ di ser etadpu#"f(etirw.ots +) +enoN=egassem_timmoc ,htapratwen.fles=htap_llab_rat ,dit=di +(yrotisoper_etadpu.seirotisoper.st = ser +:yrt +]i[sdir = dit +)eman_loot.fles(xedni.semanr = i +:esle +)"n\}ser{=ser }dit{=dit }eman_loot.sgra.fles{ yrotisoper_etaerc#"f(etirw.ots +)enoN ,"di"(teg.ser = dit +) +,DItac=sdi_yrogetac +,enoN=lru_egapemoh +,lru_dehsloot.sgra.fles=lru_yrotisoper_etomer +,"detcirtsernu"=epyt +,csed_loot.sgra.fles=noitpircsed +,csed_loot.sgra.fles % "s%:sisponyS"=sisponys +,eman_loot.sgra.fles=eman +(yrotisoper_etaerc.seirotisoper.st = ser +]ic[sdic = DItac +)tacft(xedni.semanc = ic +:semanc ni )(pirts.tacft fi +enoN = DItac +]tacst ni x rof )"?" ,"di"(teg.x[ = sdic +]tacst ni x rof )(pirts.)"?" ,"eman"(teg.x[ = semanc +)(seirogetac_teg.seirogetac.st = tacst +:semanr ni ton eman_loot.fles fi +"sloot detareneg yrotcaFlooT" = tacft +]soper ni x rof )"?" ,"di"(teg.x[ = sdir +]soper ni x rof )"?" ,"eman"(teg.x[ = semanr +)(seirotisoper_teg.seirotisoper.st = soper +) +,eslaF=yfirev +,yek_ipa_dehsloot.sgra.fles=yek +,lru_dehsloot.sgra.fles=lru +(ecnatsnIdehSlooT.dehsloot = st + +)"w" ,golt.fles(nepo = ots +:esle +)"a" ,golt.fles(nepo = ots +:)golt.fles(stsixe.htap.so fi +""" + +gnitsixe etadpu ro +yrotisoper wen etaerc ot dnelboib esu +""" +:)fles(daoLdehs fed + + + + + + +)eurT=tnirp_ytterp ,htapct(etirw.eert +)"elif",noitcesFT(ybnerdlihctros +)}eliflmx :"elif"{ ,"loot" ,noitcesFT(tnemelEbuS.TE +wen # :sloot_fnoc ni ton eliflmx fi +]sloot_ruo ni x rof ]"elif"[birtta.x[ = sloot_fnoc +)"loot"(lladnif.noitcesFT = sloot_ruo +!pot eht ta # )noitcesFT ,0(tresni.toor +)}"slooT lacoL":"eman" ,"slootlacol":"di"{ ,"noitces"(tnemelE.TE = noitcesFT +:FTsah ton fi +]0[e = noitcesFT +eurT = FTsah +:0 > )e(nel fi +)"noitces"(lladnif.toor = e +eslaF = FTsah +)(toorteg.eert = toor +)resrap ,htapct(esrap.TE = eert +)eurT=txet_knalb_evomer(resraPLMX.TE = resrap +)eman_loot.fles % 'lmx.s%' ,eman_loot.fles ,sloot_lacol.fles(nioj.htap.so = eliflmx +)'lmx.fnoc_loot_lacol/gifnoc',toor_yxalag.sgra.fles(nioj.htap.so = htapct + +))rtta(teg.dlihc :dlihc adbmal=yek ,tnerap(detros = ]:[tnerap +:)rtta ,tnerap(ybnerdlihctros fed + +:) fles(fnocloot_etadpu fed + + +edocnruter.p nruter +)(esolc.tuot +) +,tuot=tuodts +,tuot=rredts +,ridtuoloot.fles=dwc +,eslaF=llehs +,llc +(nur.ssecorpbus = p +] +,)laerx(htapsba.htap.so +,"atad_tset_etadpu--" +,toor_yxalag.sgra.fles +,"toor_yxalag--" +,)htap_tset_loot(htapsba.htap.so +,"tuptuo_tset--" +,)ridtset.fles(htapsba.htap.so +,"atad_tset--" +,"sreniatnocoib--" +,"tini_otua_adnoc--" +,"tset" +,"omenalp" +[ = llc +)"w" ,golt.fles(nepo = tuot +:esle +)"a" ,golt.fles(nepo = tuot +:)golt.fles(stsixe.htap.so fi +) +"lmth.troper_tset_omenalp_}eman_loot.fles{"f ,ridper.fles +(nioj.htap.so = htap_tset_loot +eman_loot.fles % "lmx.s%" = laerx +""" +gnitset rof elbaliava si os tnemeriuqer a si omenalp""" +:)fles(etadpu_tset_omenalp fed + + +)(esolc.ft +))"zg.dehsloot_detsetnu_}eman_loot.fles{"f ,ridtuoloot.fles(nioj.htap.so ,htapratwen.fles(ypoc.lituhs +) +,noitcnuf_edulcxe=retlif +,eman_loot.fles=emancra +,ridtuoloot.fles=eman +(dda.ft +)"zg:w" ,htapratwen.fles(nepo.elifrat = ft +) +)ridtset.fles ,tsedt( % +".s% nur omenalp retfa ridtset ni dnuof ton s% elif tuptuo - deliaf evah yam looT###" +(tnirp +:liaf_troper fi +:esle +)tsed ,crs(elifypoc.lituhs +))]'tamrof'[p,emano( % "s%.elpmas.s%" ,ridper.fles(nioj.htap.so = tsed +)tsedt ,crs(elifypoc.lituhs +:)crs(elifsi.htap.so fi +:)tsedt(elifsi.htap.so ton fi +)emano ,ridtset.fles(nioj.htap.so = crs +)emano % "elpmas_s%" ,ridtset.fles(nioj.htap.so = tsedt +]"eman"[p = emano +:seliftuo.fles ni p rof + +ofnirat esle )emedulcxe(htiwsdne.emanelif fi enoN nruter +eman.ofnirat = emanelif +:)ofnirat(noitcnuf_edulcxe fed + +"lmth.troper_tset_omenalp_" = emedulcxe +"""llabrat eht eraperp dna atad-tset otni stuptuo evom""" +:)eslaF=liaf_troper ,fles(raTlooTekam fed + +)eurT=ko_tsixe_srid ,tsed,ridtuoloot.fles(eertypoc.lituhs +)eman_loot.fles ,sloot_lacol.fles(nioj.htap.so = tsed +)tsed ,htp(elifypoc.lituhs +) +)]"tamrof"[p ,]"emanelifni"[p( % "s%.elpmas_s%" ,ridper.fles +(nioj.htap.so = tsed +)tsed ,htp(elifypoc.lituhs +)]"emanelifni"[p % "elpmas_s%" ,ridtset.fles(nioj.htap.so = tsed +]"eman"[p = htp +:selifni.fles ni p rof +)tuox ,laerx(elifypoc.lituhs +)laerx ,ridper.fles(nioj.htap.so = tuox +)tuox ,laerx(elifypoc.lituhs +)laerx ,ridtuoloot.fles(nioj.htap.so = tuox +eman_loot.fles % "lmx.s%" = laerx +)emants ,elifs.fles(elifypoc.lituhs +:)emants(stsixe.htap.so ton fi +)elifs.fles ,ridtuoloot.fles(nioj.htap.so = emants +:htap_tpircs.sgra.fles fi +)(LMXekam.fles +:esle +)(marapLMXoNod.fles +:0 == ssapmarap.sgra.fles fi +"""ecalp otni selpmas tupni dna slmx etirw""" +:)fles(looTekam fed + +)(esolc.flmay +)eurT=edocinu_wolla ,flmay ,tcido(pmud.lmay +} +,"slooT detareneG FT" :"yrogetac" +,csed_loot.sgra.fles :"sisponys" +,csed_loot.sgra.fles :"noitpircsed" +,"detcirtsernu" :"epyt" +,resuy :"renwo" +,eman_loot.fles :"eman" +{ = tcido +)"w" ,emanfy(nepo = flmay +)"lmy.dehs." ,ridtuoloot.fles(nioj.htap.so = emanfy +]0[)"@"(tilps.liame_resu.sgra.fles = resuy +"""omenalp rof""" +:)fles(lmydehSetirw fed + +meti yrotsih yxalag # +)"n\"(etirw.fx +)lmxe(etirw.fx +:fx sa )"w" ,eman_loot.fles % "lmx.s%"(nepo htiw +dexif = lmxe +)2trap ,)edirrevo_tset.fles(nioj."n\" ,1trap( % "s%n\s%n\s%" = dexif +]1[)">stset/<"(tilps.lmxe = 2trap +]0[)">stset<"(tilps.lmxe = 1trap +stset rof stcejbo lmxl stcepxe ti sa lmxyxalag edisni siht od tonnac # :) +edirrevo_tset.fles +( fi +detpecca RP litnu dnuora krow yraropmet # )"" ,EXEEKAF(ecalper.0lmxe = lmxe +)(tropxe.lootwen.fles = 0lmxe +))LRUyrotcaFloot( % "s% :ta tig ni ecruoS"(tnemmoc_dda.lootwen.fles +) +))(wonemit ,liame_resu.sgra.fles( % +".yrotcaF looT yxalaG eht gnisu s% ta s% yb detaerC" +(tnemmoc_dda.lootwen.fles +stset = stset.lootwen.fles +)a_tset(dneppa.stset +)pt(dneppa.a_tset +:maraptset.fles ni pt rof +)(tseT.ptxg = a_tset +)(stseT.ptxg = stset +selifgifnoc = selifgifnoc.lootwen.fles +) +))tpircSdepacse.fles(nioj."n\"=txet ,"emnur"=eman(elifgifnoC.ptxg +(dneppa.selifgifnoc +)(selifgifnoC.ptxg = selifgifnoc +:htap_tpircs.sgra.fles fi +stupnit.fles = stupni.lootwen.fles +stuptuot.fles = stuptuo.lootwen.fles +)(marapLMXod.fles +:esle +)(marapLMXoNod.fles +:"0" == ssapmarap.sgra.fles fi +stnemeriuqer = stnemeriuqer.lootwen.fles +)2(tixe.sys +) +,segakcap.sgra.fles +,"= esrap tonnac - deilppus gnirts segakcap demroflam ###" +(tnirp +:noitpecxE tpecxe +)d(dneppa.vneadnoc.fles +) +)rev ,)(pirts.gkcap ,"egakcap"(tnemeriuqeR.ptxg +(dneppa.stnemeriuqer +:gkcap fi +enoN = rev +:"" == rev fi +enoN = rev +)(pirts.d = gkcap +:esle +)(pirts.gkcap = gkcap +)(pirts.rev = rev +)":"(tilps.d = rev ,gkcap +:d ni ":" fi +)":" ,"="(ecalper.d = d +)":" ,"=="(ecalper.d = d +enoN = gkcap +enoN = rev +:)","(tilps.segakcap.sgra.fles ni d rof +:yrt +:segakcap.sgra.fles fi +][ = vneadnoc.fles +)(stnemeriuqeR.ptxg = stnemeriuqer +dts = soidts.lootwen.fles +)1dts(dneppa.dts +)(oidtS.ptxg = 1dts +)(soidtS.ptxg = dts +'"}noisrev_loot.sgra.fles{" ohce'f = dnammoc_noisrev.lootwen.fles +txetrefas = pleh.lootwen.fles +)rcs(nioj."n\" + txetrefas = txetrefas +)"n\"(dneppa.rcs +) +]:001-[rcs + +]"...... " ,"deteled ffuts - senil 003> "[ + +]001:[rcs +( = rcs +:003 > )rcs(nel fi +)"n\::tpircSn\n\" ,0(tresni.rcs +]"" > )(pirts.x fi tpircSdecaps.fles ni x rof x[ = rcs +!dewolla noitisnart # "n\------n\n\" + txetrefas = txetrefas +:0 > )txetrefas(nel fi +:htap_tpircs.sgra.fles fi +) +)liame_resu.sgra.fles( % +"n\esaelp txet pleh htiw dliuber ot )s%( rohtua loot eht ksA" +( = txetrefas +:0 == ))(pirts.txetrefas(nel fi +)]txetpleh ni x rof )x(epacse_hateehc[(nioj."n\" = txetrefas +)(senildaer.)"r" ,txet_pleh.sgra.fles(nepo = txetpleh +:txet_pleh.sgra.fles fi +"" = txetrefas +etic = snoitatic.lootwen.fles +)etica(dneppa.etic +)"375stb/scitamrofnioib/3901.01"=eulav ,"iod"=epyt(noitatiC.ptxg = etica +)(snoitatiC.ptxg = etic +lclmx.fles = edirrevo_dnammoc.lootwen.fles +:esle +elif gifnoc # edirrevo_dnammoc.fles = edirrevo_dnammoc.lootwen.fles +:edirrevo_dnammoc.fles fi +""" +...redro tcerroc otni enil dnammoc eht teg ot woH .mmmH +lmthyxalag sesU +tpircs wen eht rof repparw loot lmx yxalaG a etaerC +""" +aqon # :)fles(LMXekam fed + +)pt(dneppa.maraptset.fles +)emanwen % "elpmas_s%"=eulav ,emanwen=eman(tuptuOtseT.ptxg = pt +)tuona(dneppa.stuptuot.fles +lanoitisop_si.fles = lanoitisop.tuona +emanwen % "s%$ >" = edirrevo_enil_dnammoc.tuona +)0=sehsad_mun ,tmfwen=tamrof ,emanwen(ataDtuptuO.ptxg = tuona +]"tamrof"[]0[seliftuo.fles = tmfwen +]"eman"[]0[seliftuo.fles = emanwen +:0 > )seliftuo.fles(nel fi +)pt(dneppa.maraptset.fles +)emanwen % "elpmas_s%"=eulav ,emanwen=eman(maraPtseT.ptxg = pt +)tupnina(dneppa.stupnit.fles +eurT = lanoitisop.tupnina +emanwen % "s%$ <" = edirrevo_enil_dnammoc.tupnina +) +,0=sehsad_mun +,eslaF=elpitlum +,]"tamrof"[]0[selifni.fles=tamrof +,]"pleh"[]0[selifni.fles=pleh +,bala=lebal +,eslaF=lanoitpo +,emanwen +(maraPataD.ptxg = tupnina +]"emanelifni"[]0[selifni.fles = emanwen +s1xam ,1 == )selifni.fles(nel tressa +) +)selifni.fles(rts % +"s% - deilppus selif tupni elpitlum tub 0 si ssapmarap fi tupni eno mumixaM" +( = s1xam +]"emanelifni"[]0[selifni.fles = bala +:0 == )bala(nel fi +]"lebal"[]0[selifni.fles = bala +:0 > )selifni.fles(nel fi +"""tuodts ot nidts - egakcap elyts retlif""" +:)fles(marapLMXoNod fed + +) +"!neht litnu neddir-revo eb tsum snoitcelloc rof stset - tey degrem RP eht evah ton seod noisrev lmxyxalaG :GNINRAW ####" +(tnirp +:noitpecxE tpecxe +)mrapt(dneppa.maraptset.fles +.degrem RP litnu nekorb # )emanwen(noitcelloCtuptuOtseT.ptxg = mrapt +:yrt +)tcelloc(dneppa.stuptuot.fles +)csid(dneppa.tcelloc +) +"eslaf"=elbisiv ,"}emanwen{"f=yrotcerid ,csidwen=nrettap +(stesataDrevocsiD.ptxg = csid +)dnikwen=epyt ,lebalwen=lebal ,emanwen(noitcelloCtuptuO.ptxg = tcelloc +]"revocsid"[p = csidwen +]"lebal"[p = lebalwen +]"eman"[p = emanwen +]"dnik"[p = dnikwen +:snoitcelloc.fles ni p rof +) +)emanwen ,epytwen( % +'LMXekam ni s% retemarap txettceles +\rof "s%" epyt retemarap desingocernU' +(rorrEeulaV esiar +:esle +)mrapt(dneppa.maraptset.fles +)lavwen=eulav ,emanwen(maraPtseT.ptxg = mrapt +)mrapa(dneppa.stupnit.fles +)lcwen(tni = lanoitisop.mrapa +:lanoitisop_si.fles fi +lanoitisop_si.fles = lanoitisop.mrapa +)tpona(dneppa.mrapa +) +,]i[txetwen=txet +,]i[lavwen=eulav +(noitpOtceleS.ptxg = tpona +:))lavwen(nel(egnar ni i rof +) +,hsadn=sehsad_mun +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPtceleS.ptxg = mrapa +]"stxet"[p = txetwen +:"txettceles" == epytwen fi +)emanwen(hsadNteg.fles = hsadn +emanwen = lebalwen +:0 > )lebalwen(nel ton fi +]"LC"[p = lcwen +]"epyt"[p = epytwen +]"pleh"[p = plehwen +]"lebal"[p = lebalwen +]"eulav"[p = lavwen +]"eman"[p = emanwen +:raples.fles ni p rof +)mrapt(dneppa.maraptset.fles +)lavwen=eulav ,emanwen(maraPtseT.ptxg = mrapt +)mrapa(dneppa.stupnit.fles +:esle +)mrapt(dneppa.maraptset.fles +)2mrapt(dneppa.mrapt +)lavwen=eulav ,emanwen(maraPtseT.ptxg = 2mrapt +)"}emanwen{_R"f=eman(taepeRtseT.ptxg = mrapt +)eper(dneppa.stupnit.fles +)mrapa(dneppa.eper +) +"dedeen sa }lebalwen{ ynam sa ddA"f=eltit ,"}emanwen{_R"f=eman +(taepeR.ptxg = eper +:sper fi +)lcdlo(tni = lanoitisop.mrapa +:lanoitisop_si.fles fi +lanoitisop_si.fles = lanoitisop.mrapa +) +)emanwen ,epytwen( % +'LMXekam ni s% retemarap lanoitidda +\rof "s%" epyt retemarap desingocernU' +(rorrEeulaV esiar +:esle +) +,hsadn=sehsad_mun +,lavwen=eulav +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPnaelooB.ptxg = mrapa +:"naeloob" == epytwen file +) +,hsadn=sehsad_mun +,lavwen=eulav +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPtaolF.ptxg = mrapa +:"taolf" == epytwen file +) +,hsadn=sehsad_mun +,lavwen=eulav +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPregetnI.ptxg = mrapa +:"regetni" == epytwen file +) +,hsadn=sehsad_mun +,lavwen=eulav +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPtxeT.ptxg = mrapa +:"txet" == epytwen fi +)emanwen(hsadNteg.fles = hsadn +emanwen = lebalwen +:0 > )lebalwen(nel ton fi +"1" == ]"taeper"[p = sper +]"LCgiro"[p = lcdlo +]"LC"[p = lcwen +]"epyt"[p = epytwen +]"pleh"[p = plehwen +]"lebal"[p = lebalwen +]"eulav"[p = lavwen +]"eman"[p = emanwen +:rapdda.fles ni p rof +)mrapt(dneppa.maraptset.fles +)emanwen % "elpmas_s%"=eulav ,emanwen(maraPtseT.ptxg = mrapt +)tupnina(dneppa.stupnit.fles +:esle +)mrapt(dneppa.maraptset.fles +)2mrapt(dneppa.mrapt +)emanwen % "elpmas_s%"=eulav ,emanwen(maraPtseT.ptxg = 2mrapt +)"}emanwen{_R"f=eman(taepeRtseT.ptxg = mrapt +)eper(dneppa.stupnit.fles +)tupnina(dneppa.eper +) +"dedeen sa }bala{ ynam sa ddA"f=eltit ,"}emanwen{_R"f=eman +(taepeR.ptxg = eper +:sper fi +emanwen % "s%$" = edirrevo_enil_dnammoc.tupnina +)]"LCgiro"[p(tni = lanoitisop.tupnina +:esle +emanwen % "s%$ <" = edirrevo_enil_dnammoc.tupnina +8999999 = lanoitisop.tupnina +:"NIDTS" == )(reppu.]"LCgiro"[p fi +:lanoitisop_si.fles fi +lanoitisop_si.fles = lanoitisop.tupnina +) +,hsadn=sehsad_mun +,eslaF=elpitlum +,tmfwen=tamrof +,]"pleh"[p=pleh +,bala=lebal +,eslaF=lanoitpo +,emanwen +(maraPataD.ptxg = tupnina +]"lebal"[p = bala +:esle +]"LC"[p = bala +:0 > )]"lebal"[p(nel ton fi +"1" == )"0" ,"taeper"(teg.p = sper +)emanwen(hsadNteg.fles = hsadn +]"tamrof"[p = tmfwen +]"emanelifni"[p = emanwen +:selifni.fles ni p rof +)pt(dneppa.maraptset.fles +) +,c=erapmoc +,emanwen % "elpmas_s%"=eulav +,emanwen=eman +(tuptuOtseT.ptxg = pt +tset = c +:esle +) +,carf_atled=carf_atled +,atled=atled +,c=erapmoc +,emanwen % "elpmas_s%"=eulav +,emanwen=eman +(tuptuOtseT.ptxg = pt +enoN = carf_atled +)nt(tni = atled +:esle +))nt(taolf ,0.1(nim = carf_atled +enoN = atled +:nt ni "." fi +:"" > nt fi +)(pirts.]1[)":"(tilps.tset = nt +"ezis_mis" = c +:)"ezis_mis"(htiwstrats.tset file +) +,dl=ffid_senil +,c=erapmoc +,emanwen % "elpmas_s%"=eulav +,emanwen=eman +(tuptuOtseT.ptxg = pt +)]1[)":"(tilps.tset(tni = dl +:tigidsi.]1[)":"(tilps.tset fi +0 = dl +"ffid" = c +:)"ffid"(htiwstrats.)(pirts.tset fi +:"" > )(pirts.tset fi +enoN = dl +)mrapa(dneppa.stuptuot.fles +emanwen % "s%$" = edirrevo_enil_dnammoc.mrapa +)lcdlo(tni = lanoitisop.mrapa +:esle +emanwen % "s%$ >" = edirrevo_enil_dnammoc.mrapa +9999999 = lanoitisop.mrapa +:"TUODTS" == )(reppu.lcdlo fi +:lanoitisop_si.fles fi +lanoitisop_si.fles = lanoitisop.mrapa +) +emanwen=lebal ,hsadn=sehsad_mun ,tmfwen=tamrof ,emanwen=eman +(ataDtuptuO.ptxg = mrapa +)lcwen(hsadNteg.fles = hsadn +)(pirts.tset = tset +]"LCgiro"[p = lcdlo +]"tset"[p = tset +]"LC"[p = lcwen +]"tamrof"[p = tmfwen +]"eman"[p = emanwen +:seliftuo.fles ni p rof +"""loot ot stnemele dedeen lla ddA""" +aqon # :)fles(marapLMXod fed + +hsadn nruter +1 = hsadn +:2 < )emanwen(nel fi +2 = hsadn +:esle +0 = hsadn +:lanoitisop_si.fles fi +:)emanwen ,fles(hsadNteg fed + +)c(LCXa +:plc ni c rof +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)lc(LCXa +:tceriderlcxtsal.fles ni lc rof +:tceriderlcxtsal.fles fi +)v(LCXa +)k(LCXa +k % "s%--" = k +:esle +k % "s%-" = k +:1 == ))(pirts.k(nel fi +:esle +)k(LCXa +edirrevok = k +:"" > edirrevok fi +:xiffuslcx.fles ni )edirrevok ,v ,k( rof + +mrof deman esrapgra ni smarap neht stupni # +dneppa.lclmx.fles = LCXa +"""elyts esrapgra""" +:)fles(esrapgralc fed + +)c(LCXa +:plc ni c rof +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)lc(LCXa +:tceriderlcxtsal.fles ni lc rof +:tceriderlcxtsal.fles fi +)v(LCXa +:xiffuslcx.fles ni )edirrevok ,v ,k( rof +dneppa.lclmx.fles = LCXa +smarap neht redro ni stupni # +:)fles(lanoitisoplc fed + +pdda = ]i[rapdda.fles +]"LC"[pdda = ]"LCgiro"[pdda +)p(ypoc.ypoc = pdda +:)rapdda.fles(etaremune ni p ,i rof +pftuo = ]i[seliftuo.fles +ypoc peek # ]"LC"[pftuo = ]"LCgiro"[pftuo +)p(ypoc.ypoc = pftuo +:)seliftuo.fles(etaremune ni p ,i rof +pfni = ]i[selifni.fles +]"LC"[pfni = ]"emanelifni"[pfni +:esle +)"_" ," "(ecalper.]"lebal"[pfni = ]"emanelifni"[pfni +:]"0" ,"lanoitisop"[ ni ssapmarap.sgra.fles fi +]"LC"[pfni = ]"LCgiro"[pfni +)p(ypoc.ypoc = pfni +:)selifni.fles(etaremune ni p ,i rof +) +,]"eman"[p +,]"LC"[p +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,)(tigidsi.] +"LC" +[p tressa +:)rapdda.fles(etaremune ni p ,i rof +) +,]"eman"[p +,]"LC"[p +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,) +"TUODTS" == )(reppu.)(pirts.]"LC"[p ro )(tigidsi.]"LC"[p +( tressa +:)seliftuo.fles(etaremune ni p ,i rof +) +,]"lebal"[p +,]"LC"[p +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,) +"NIDTS" == )(reppu.)(pirts.]"LC"[p ro )(tigidsi.]"LC"[p +( tressa +:)selifni.fles(etaremune ni p ,i rof +:"lanoitisop" == ssapmarap.sgra.fles fi +"""lanidro ciremun rieht yb detacilpmoc era sretemarap lanoitisop """ +:)fles(rappunaelc fed + +)(esolc.tcafitra +))"8ftu" ,tpircs.fles(setyb(etirw.tcafitra +)"bw" ,tra(nepo = tcafitra +)]0[emetucexe.fles ,eman_loot.fles( % "s%.s%" = tra +xr = tpircSdepacse.fles +)"war dne#"(dneppa.xr +)"war#" ,0(tresni.xr +]"" > )(pirts.x fi xr ni x rof "}x{ "f[ = tpircSdecaps.fles +)(esolc.tpircst +)tpircs.fles(etirw.tpircst +)"w" ,elifs.fles(nepo = tpircst +) +)]0[emetucexe.fles( % "s%_"=xiffus ,eman_loot.fles=xiferp +(pmetskm.elifpmet = elifs.fles ,eldnahf +)xr(nioj."n\" = tpircs.fles +"nur tonnaC .ytpme si tpircs deilppuS" ,0 > )kcehcxr(nel tressa +]"" > )(pirts.x fi xr ni x rof )(pirts.x[ = kcehcxr +]xr ni x rof )(pirtsr.x[ = xr +)(senildaer.)"r" ,htap_tpircs.sgra.fles(nepo = xr +:)fles(tpircSperp fed + +xiffuslcx = xiffuslcx.fles +)(tros.xiffuslcx +)]]"edirrevo"[p ,]"eman"[p % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +:raples.fles ni p rof +)]revo ,man % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +]"edirrevo"[p = revo +) +"!senil dnammoc retemarap lanoitisop ni dettimrep ton - derongi }man{ rof staepeR .gninraw ###"f +(tnirp +:per fi +esnes ON ekam staeper # "1" == ]"taeper"[p = per +]"eman"[p = man +:rapdda.fles ni p rof +)]"" ,]"eman"[p % "s%$" ,]"LC"[p[(dneppa.xiffuslcx +:esle +]]"eman"[p % "s%$" ,">"[ = tceriderlcxtsal.fles +:"TUODTS" == )(reppu.)(pirts.]"LCgiro"[p fi +:)seliftuo.fles(etaremune ni p ,i rof +)emdneppax(dneppa.xiffuslcx +]"" ,]"emanelifni"[p % "s%$" ,]"LC"[p[ = emdneppax +:esle +] +,]"emanelifni"[p % "s%$ <" +,]"emanelifni"[p +,"999" +[ = emdneppax +:"NIDTS" == )(reppu.)(pirts.]"LCgiro"[p fi +:)selifni.fles(etaremune ni p ,i rof +][ = xiffuslcx +:)fles(soplcperp fed + +xiffuslcx = xiffuslcx.fles +)]]"edirrevo"[p ,]"eman"[p % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +:raples.fles ni p rof +)]revo ,man % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +]"edirrevo"[p = revo +:esle +'rof dne#n\"}man{.per$" }man{--n\:}man{_R$ ni per$ rof#'f = revo +:per fi +"1" == ]"taeper"[p = per +]"eman"[p = man +:rapdda.fles ni p rof +)]"" ,]"eman"[p % "s%$" ,]"eman"[p[(dneppa.xiffuslcx +:esle +]]"eman"[p % "s%$" ,">"[ = tceriderlcxtsal.fles +:"TUODTS" == )(reppu.)(pirts.]"LCgiro"[p fi +:)seliftuo.fles(etaremune ni p ,i rof +)emdneppax(dneppa.xiffuslcx +]revo ,]"LC"[p % "s%$" ,]"LC"[p[ = emdneppax +'rof dne#n\"}man{.per$" }man{--n\:}man{_R$ ni per$ rof#'f = revo +:per fi +"" = revo +"1" == ]"taeper"[p = per +:esle +] +,man % "s%$ <" +,man +,man +[ = emdneppax +:"NIDTS" == )(reppu.)(pirts.]"LCgiro"[p fi +]"emanelifni"[p = man +:)selifni.fles(etaremune ni p ,i rof +][ = xiffuslcx +:)fles(pgraperp fed + +)c(LCXa +:plc ni c rof +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)]"eman"[]0[seliftuo.fles % "s%$"(LCXa +)">"(LCXa +:0 > )seliftuo.fles(nel fi +)]"emanelifni"[]0[selifni.fles % "s%$"(LCXa +)"<"(LCXa +:0 > )selifni.fles(nel fi +dneppa.lclmx.fles = LCXa +"""o/i rof > dna < sesu - staeper ro sretemarap on""" +:)fles(elpmislc fed + +)(esrapgralc.fles +)(pgraperp.fles +:esle +)(lanoitisoplc.fles +)(soplcperp.fles +:"lanoitisop" == ssapmarap.sgra.fles fi +:esle +)(elpmislc.fles +:"0" == ssapmarap.sgra.fles fi + +)xe(LCXa +:emetucexe.fles ni xe rof +:esle +)"emnur$"(LCXa +)xe(LCXa +:emetucexe.fles ni xe rof +:htap_tpircs.sgra.fles fi +enoN = edirrevo_tset.fles +:esle +]sots ni x rof )(pirtsr.x[ = edirrevo_tset.fles +)(senildaer.)"r" ,edirrevo_tset.sgra.fles(nepo = sots +:edirrevo_tset.sgra.fles fi +enoN = edirrevo_dnammoc.fles +:esle +]socs ni x rof )(pirtsr.x[ = edirrevo_dnammoc.fles +)(senildaer.)"r" ,edirrevo_dnammoc.sgra.fles(nepo = socs +:edirrevo_dnammoc.sgra.fles fi +)(tpircSperp.fles +:htap_tpircs.sgra.fles fi +][ = maraptset.fles +)(stuptuO.ptxg = stuptuot.fles +)(stupnI.ptxg = stupnit.fles +)eman_loot.fles % 'txt.gol_nur_FT_s%',ridper.fles(nioj.htap.so = golt.fles +)ridper.fles(ridkm.so +:)ridper.fles(stsixe.htap.so ton fi +)ridtset.fles(ridkm.so +:)ridtset.fles(stsixe.htap.so ton fi +)ridtuoloot.fles(ridkm.so +:)ridtuoloot.fles(stsixe.htap.so ton fi +)"atad-tset" ,ridtuoloot.fles(nioj.htap.so = ridtset.fles +)eman_loot.fles % "zg.dehsloot_detset_ton_s%" ,ridtuoloot.fles(nioj.htap.so # tuo_loot_detsetnu.sgra = htapratwen.fles +"negloot/." = ridper.fles +"tuoft/." = ridtuoloot.fles +) +,EXEEKAF +,csed_loot.sgra.fles +,noisrev_loot.sgra.fles +,di_loot.fles +,eman_loot.fles +(looT.txg = lootwen.fles +eman_loot.fles = di_loot.fles +)eman_loot.sgra ,"" ,"+]_9-0Z-Az-a^["(bus.er = eman_loot.fles +'"esrapgra" ro "lanoitisop","0" eb tsum ssapmarap.sgra' ,] +,"lanoitisop" +,"esrapgra" +,"0" +[ ni ssapmarap.sgra tressa +dneppa.lclmx.fles = LCXa +enoN = emetucexe.fles +:esle +] +,)(pirts.]0[)":"(tilps.]0[)","(tilps.segakcap.sgra.fles +[ = emetucexe.fles +:segakcap.sgra.fles fi +:esle +] +,exesys.sgra.fles +[ = emetucexe.fles +:esle +)exesys.sgra.fles(tilps.xelhs = emetucexe.fles +:exesys.sgra.fles ni " " fi +:exesys.sgra.fles fi +"lanoitisop" == ssapmarap.sgra.fles = lanoitisop_si.fles +][ = lclmx.fles +enoN = tceriderlcxtsal.fles +)(rappunaelc.fles +sgra = sgra.fles +) +"yranoitcid a eb dluohs - demroflam si }sretemarap_txettceles.sgra{ sretemarap_txettceles--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi sretemarap_txettceles.sgra ni x rof )x(sdaol.nosj +[ = raples.fles +:yrt +) +"yranoitcid a eb dluohs - demroflam si }sretemarap_lanoitidda.sgra{ sretemarap_lanoitidda--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi sretemarap_lanoitidda.sgra ni x rof )x(sdaol.nosj +[ = rapdda.fles +:yrt +'tros emos fo tuptuo na tuohtiw liaf lliw rennur boj yxalaG ehT .deificeps snoitcelloc tuptuo ro seliftuo oN' ,0 > ))snoitcelloc.fles(nel + )seliftuo.fles(nel( tressa +) +"yranoitcid a eb dluohs - demroflam si }selif_tuptuo.sgra{ retemarap selif_tuptuo--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi selif_tuptuo.sgra ni x rof )x(sdaol.nosj +[ = seliftuo.fles +:yrt +) +"yranoitcid a eb dluohs - demroflam si })selif_tupni.sgra(rts{ retemarap selif_tupni--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi selif_tupni.sgra ni x rof )x(sdaol.nosj +[ = selifni.fles +:yrt +) +"yranoitcid a eb dluohs - demroflam si })noitcelloc.sgra(rts{ retemarap snoitcelloc--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi noitcelloc.sgra ni x rof )x(sdaol.nosj +[ = snoitcelloc.fles +:yrt +:0 > )noitcelloc.sgra(nel fi +][ = snoitcelloc.fles +)(dwcteg.so = dwcruo.fles +)'sloot_lacol',toor_yxalag.sgra(nioj.htap.so = sloot_lacol.fles +""" +noitareneg loot lmxyxalag rof dedeen stnemele eraperp dna +ereh loot eht gninnur rof lc enil dnammoc eraperp +""" +aqon # :)enoN=sgra ,fles(__tini__ fed + +""" + +lmxyxalag sesu +tpircs yrartibra na rof repparW""" +:yrotcaF_looT ssalc + + +selput_noitatic nruter +)))(pirts.]: )"xetbib"(nel[noitatic ,"xetbib"((dneppa.selput_noitatic +:esle +)))(pirts.]: )"iod"(nel[noitatic ,"iod"((dneppa.selput_noitatic +:)"iod"(htiwstrats.noitatic fi +:snoitatic ni noitatic rof +][ = selput_noitatic +])(pirts.c fi )"**YRTNE**"(tilps.txet_snoitatic ni c rof c[ = snoitatic +"""""" +:)txet_snoitatic(snoitatic_esrap fed + + +)]txet ni c rof )c ,c(teg.elbat_epacse_hateehc[(nioj."" nruter +""".txet nihtiw seititne ecudorP""" +:)txet(epacse_hateehc fed + + +}"#\\" :"#" ,"$\\" :"$"{ = elbat_epacse_hateehc + + +)))(emit.emit(emitlacol.emit ,"S%:M%:H% Y%/m%/d%"(emitfrts.emit nruter +"""gnirts a sa emit tnerruc nruter""" +:)(wonemit fed + + +.edirrevo htiw # +neve exe eht gnidneperp lmxyxalag xif ot pmub noisrev/RP a litnu siht deen # +"~~~EM~~~EVOMER~~~" = EXEEKAF +"yrotcafloot/2rabuf/moc.buhtig//:sptth" = LRUyrotcaFloot +eurT = gubed +eurT = esobrev +"2202 hcraM 4.2V" = noisrevym + +lmay tropmi + +TE sa eerte.lmxl tropmi + +ptxg sa sretemarap.loot.lmxyxalag tropmi +txg sa loot.lmxyxalag tropmi + +yxalag tropmi dnelboib morf + +emit tropmi +elifpmet tropmi +elifrat tropmi +sys tropmi +ssecorpbus tropmi +lituhs tropmi +xelhs tropmi +er tropmi +so tropmi +nosj tropmi +ltncf tropmi +ypoc tropmi +esrapgra tropmi + + + +.tset htiw loot reporp wen a snruter dna # +stuptuo tset eht setaerc ,evihcra detset-non a no omenalp snur retset ehT # +noitpoda reniatnocoib dna tnempoleved lairotut NTG fo trap sa # +llatsni/tset dna etareneg - sloot owt otni derotcafeR :2202 hcram # +# +yrotcafloot/2rabuf/moc.buhtig//:sptth # +ta emoclew sexif gub dna tnemevorpmi rof snoitseggus # +LPGL eht rednu desneciL # +devreser sthgir lla # +# +2102 yaM )moc pots liamg ta surazal pots ssor( surazal ssor thgirypoc # +# +yrotcafloot/2rabuf/moc.buhtig//:sptth ees #
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tacrev/test-data/Input_text_file_to_be_reversed_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1210 @@ +# see https://github.com/fubar2/toolfactory +# +# copyright ross lazarus (ross stop lazarus at gmail stop com) May 2012 +# +# all rights reserved +# Licensed under the LGPL +# suggestions for improvement and bug fixes welcome at +# https://github.com/fubar2/toolfactory +# +# march 2022: Refactored into two tools - generate and test/install +# as part of GTN tutorial development and biocontainer adoption +# The tester runs planemo on a non-tested archive, creates the test outputs +# and returns a new proper tool with test. + + + +import argparse +import copy +import fcntl +import json +import os +import re +import shlex +import shutil +import subprocess +import sys +import tarfile +import tempfile +import time + +from bioblend import galaxy + +import galaxyxml.tool as gxt +import galaxyxml.tool.parameters as gxtp + +import lxml.etree as ET + +import yaml + +myversion = "V2.4 March 2022" +verbose = True +debug = True +toolFactoryURL = "https://github.com/fubar2/toolfactory" +FAKEEXE = "~~~REMOVE~~~ME~~~" +# need this until a PR/version bump to fix galaxyxml prepending the exe even +# with override. + + +def timenow(): + """return current time as a string""" + return time.strftime("%d/%m/%Y %H:%M:%S", time.localtime(time.time())) + + +cheetah_escape_table = {"$": "\\$", "#": "\\#"} + + +def cheetah_escape(text): + """Produce entities within text.""" + return "".join([cheetah_escape_table.get(c, c) for c in text]) + + +def parse_citations(citations_text): + """""" + citations = [c for c in citations_text.split("**ENTRY**") if c.strip()] + citation_tuples = [] + for citation in citations: + if citation.startswith("doi"): + citation_tuples.append(("doi", citation[len("doi") :].strip())) + else: + citation_tuples.append(("bibtex", citation[len("bibtex") :].strip())) + return citation_tuples + + +class Tool_Factory: + """Wrapper for an arbitrary script + uses galaxyxml + + """ + + def __init__(self, args=None): # noqa + """ + prepare command line cl for running the tool here + and prepare elements needed for galaxyxml tool generation + """ + self.local_tools = os.path.join(args.galaxy_root,'local_tools') + self.ourcwd = os.getcwd() + self.collections = [] + if len(args.collection) > 0: + try: + self.collections = [ + json.loads(x) for x in args.collection if len(x.strip()) > 1 + ] + except Exception: + print( + f"--collections parameter {str(args.collection)} is malformed - should be a dictionary" + ) + try: + self.infiles = [ + json.loads(x) for x in args.input_files if len(x.strip()) > 1 + ] + except Exception: + print( + f"--input_files parameter {str(args.input_files)} is malformed - should be a dictionary" + ) + try: + self.outfiles = [ + json.loads(x) for x in args.output_files if len(x.strip()) > 1 + ] + except Exception: + print( + f"--output_files parameter {args.output_files} is malformed - should be a dictionary" + ) + assert (len(self.outfiles) + len(self.collections)) > 0, 'No outfiles or output collections specified. The Galaxy job runner will fail without an output of some sort' + try: + self.addpar = [ + json.loads(x) for x in args.additional_parameters if len(x.strip()) > 1 + ] + except Exception: + print( + f"--additional_parameters {args.additional_parameters} is malformed - should be a dictionary" + ) + try: + self.selpar = [ + json.loads(x) for x in args.selecttext_parameters if len(x.strip()) > 1 + ] + except Exception: + print( + f"--selecttext_parameters {args.selecttext_parameters} is malformed - should be a dictionary" + ) + self.args = args + self.cleanuppar() + self.lastxclredirect = None + self.xmlcl = [] + self.is_positional = self.args.parampass == "positional" + if self.args.sysexe: + if " " in self.args.sysexe: + self.executeme = shlex.split(self.args.sysexe) + else: + self.executeme = [ + self.args.sysexe, + ] + else: + if self.args.packages: + self.executeme = [ + self.args.packages.split(",")[0].split(":")[0].strip(), + ] + else: + self.executeme = None + aXCL = self.xmlcl.append + assert args.parampass in [ + "0", + "argparse", + "positional", + ], 'args.parampass must be "0","positional" or "argparse"' + self.tool_name = re.sub("[^a-zA-Z0-9_]+", "", args.tool_name) + self.tool_id = self.tool_name + self.newtool = gxt.Tool( + self.tool_name, + self.tool_id, + self.args.tool_version, + self.args.tool_desc, + FAKEEXE, + ) + self.tooloutdir = "./tfout" + self.repdir = "./toolgen" + self.newtarpath = args.untested_tool_out # os.path.join(self.tooloutdir, "%s_not_tested_toolshed.gz" % self.tool_name) + self.testdir = os.path.join(self.tooloutdir, "test-data") + if not os.path.exists(self.tooloutdir): + os.mkdir(self.tooloutdir) + if not os.path.exists(self.testdir): + os.mkdir(self.testdir) + if not os.path.exists(self.repdir): + os.mkdir(self.repdir) + self.tlog = os.path.join(self.repdir,'%s_TF_run_log.txt' % self.tool_name) + self.tinputs = gxtp.Inputs() + self.toutputs = gxtp.Outputs() + self.testparam = [] + if self.args.script_path: + self.prepScript() + if self.args.command_override: + scos = open(self.args.command_override, "r").readlines() + self.command_override = [x.rstrip() for x in scos] + else: + self.command_override = None + if self.args.test_override: + stos = open(self.args.test_override, "r").readlines() + self.test_override = [x.rstrip() for x in stos] + else: + self.test_override = None + if self.args.script_path: + for ex in self.executeme: + aXCL(ex) + aXCL("$runme") + else: + for ex in self.executeme: + aXCL(ex) + + if self.args.parampass == "0": + self.clsimple() + else: + if self.args.parampass == "positional": + self.prepclpos() + self.clpositional() + else: + self.prepargp() + self.clargparse() + + def clsimple(self): + """no parameters or repeats - uses < and > for i/o""" + aXCL = self.xmlcl.append + if len(self.infiles) > 0: + aXCL("<") + aXCL("$%s" % self.infiles[0]["infilename"]) + if len(self.outfiles) > 0: + aXCL(">") + aXCL("$%s" % self.outfiles[0]["name"]) + if self.args.cl_user_suffix: # DIY CL end + clp = shlex.split(self.args.cl_user_suffix) + for c in clp: + aXCL(c) + + def prepargp(self): + xclsuffix = [] + for i, p in enumerate(self.infiles): + nam = p["infilename"] + if p["origCL"].strip().upper() == "STDIN": + xappendme = [ + nam, + nam, + "< $%s" % nam, + ] + else: + rep = p["repeat"] == "1" + over = "" + if rep: + over = f'#for $rep in $R_{nam}:\n--{nam} "$rep.{nam}"\n#end for' + xappendme = [p["CL"], "$%s" % p["CL"], over] + xclsuffix.append(xappendme) + for i, p in enumerate(self.outfiles): + if p["origCL"].strip().upper() == "STDOUT": + self.lastxclredirect = [">", "$%s" % p["name"]] + else: + xclsuffix.append([p["name"], "$%s" % p["name"], ""]) + for p in self.addpar: + nam = p["name"] + rep = p["repeat"] == "1" + if rep: + over = f'#for $rep in $R_{nam}:\n--{nam} "$rep.{nam}"\n#end for' + else: + over = p["override"] + xclsuffix.append([p["CL"], '"$%s"' % nam, over]) + for p in self.selpar: + xclsuffix.append([p["CL"], '"$%s"' % p["name"], p["override"]]) + self.xclsuffix = xclsuffix + + def prepclpos(self): + xclsuffix = [] + for i, p in enumerate(self.infiles): + if p["origCL"].strip().upper() == "STDIN": + xappendme = [ + "999", + p["infilename"], + "< $%s" % p["infilename"], + ] + else: + xappendme = [p["CL"], "$%s" % p["infilename"], ""] + xclsuffix.append(xappendme) + for i, p in enumerate(self.outfiles): + if p["origCL"].strip().upper() == "STDOUT": + self.lastxclredirect = [">", "$%s" % p["name"]] + else: + xclsuffix.append([p["CL"], "$%s" % p["name"], ""]) + for p in self.addpar: + nam = p["name"] + rep = p["repeat"] == "1" # repeats make NO sense + if rep: + print( + f"### warning. Repeats for {nam} ignored - not permitted in positional parameter command lines!" + ) + over = p["override"] + xclsuffix.append([p["CL"], '"$%s"' % nam, over]) + for p in self.selpar: + xclsuffix.append([p["CL"], '"$%s"' % p["name"], p["override"]]) + xclsuffix.sort() + self.xclsuffix = xclsuffix + + def prepScript(self): + rx = open(self.args.script_path, "r").readlines() + rx = [x.rstrip() for x in rx] + rxcheck = [x.strip() for x in rx if x.strip() > ""] + assert len(rxcheck) > 0, "Supplied script is empty. Cannot run" + self.script = "\n".join(rx) + fhandle, self.sfile = tempfile.mkstemp( + prefix=self.tool_name, suffix="_%s" % (self.executeme[0]) + ) + tscript = open(self.sfile, "w") + tscript.write(self.script) + tscript.close() + self.spacedScript = [f" {x}" for x in rx if x.strip() > ""] + rx.insert(0, "#raw") + rx.append("#end raw") + self.escapedScript = rx + art = "%s.%s" % (self.tool_name, self.executeme[0]) + artifact = open(art, "wb") + artifact.write(bytes(self.script, "utf8")) + artifact.close() + + def cleanuppar(self): + """ positional parameters are complicated by their numeric ordinal""" + if self.args.parampass == "positional": + for i, p in enumerate(self.infiles): + assert ( + p["CL"].isdigit() or p["CL"].strip().upper() == "STDIN" + ), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["label"], + ) + for i, p in enumerate(self.outfiles): + assert ( + p["CL"].isdigit() or p["CL"].strip().upper() == "STDOUT" + ), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["name"], + ) + for i, p in enumerate(self.addpar): + assert p[ + "CL" + ].isdigit(), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["name"], + ) + for i, p in enumerate(self.infiles): + infp = copy.copy(p) + infp["origCL"] = infp["CL"] + if self.args.parampass in ["positional", "0"]: + infp["infilename"] = infp["label"].replace(" ", "_") + else: + infp["infilename"] = infp["CL"] + self.infiles[i] = infp + for i, p in enumerate(self.outfiles): + outfp = copy.copy(p) + outfp["origCL"] = outfp["CL"] # keep copy + self.outfiles[i] = outfp + for i, p in enumerate(self.addpar): + addp = copy.copy(p) + addp["origCL"] = addp["CL"] + self.addpar[i] = addp + + def clpositional(self): + # inputs in order then params + aXCL = self.xmlcl.append + for (k, v, koverride) in self.xclsuffix: + aXCL(v) + if self.lastxclredirect: + for cl in self.lastxclredirect: + aXCL(cl) + if self.args.cl_user_suffix: # DIY CL end + clp = shlex.split(self.args.cl_user_suffix) + for c in clp: + aXCL(c) + + def clargparse(self): + """argparse style""" + aXCL = self.xmlcl.append + # inputs then params in argparse named form + + for (k, v, koverride) in self.xclsuffix: + if koverride > "": + k = koverride + aXCL(k) + else: + if len(k.strip()) == 1: + k = "-%s" % k + else: + k = "--%s" % k + aXCL(k) + aXCL(v) + if self.lastxclredirect: + for cl in self.lastxclredirect: + aXCL(cl) + if self.args.cl_user_suffix: # DIY CL end + clp = shlex.split(self.args.cl_user_suffix) + for c in clp: + aXCL(c) + + def getNdash(self, newname): + if self.is_positional: + ndash = 0 + else: + ndash = 2 + if len(newname) < 2: + ndash = 1 + return ndash + + def doXMLparam(self): # noqa + """Add all needed elements to tool""" + for p in self.outfiles: + newname = p["name"] + newfmt = p["format"] + newcl = p["CL"] + test = p["test"] + oldcl = p["origCL"] + test = test.strip() + ndash = self.getNdash(newcl) + aparm = gxtp.OutputData( + name=newname, format=newfmt, num_dashes=ndash, label=newname + ) + aparm.positional = self.is_positional + if self.is_positional: + if oldcl.upper() == "STDOUT": + aparm.positional = 9999999 + aparm.command_line_override = "> $%s" % newname + else: + aparm.positional = int(oldcl) + aparm.command_line_override = "$%s" % newname + self.toutputs.append(aparm) + ld = None + if test.strip() > "": + if test.strip().startswith("diff"): + c = "diff" + ld = 0 + if test.split(":")[1].isdigit: + ld = int(test.split(":")[1]) + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + lines_diff=ld, + ) + elif test.startswith("sim_size"): + c = "sim_size" + tn = test.split(":")[1].strip() + if tn > "": + if "." in tn: + delta = None + delta_frac = min(1.0, float(tn)) + else: + delta = int(tn) + delta_frac = None + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + delta=delta, + delta_frac=delta_frac, + ) + else: + c = test + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + ) + self.testparam.append(tp) + for p in self.infiles: + newname = p["infilename"] + newfmt = p["format"] + ndash = self.getNdash(newname) + reps = p.get("repeat", "0") == "1" + if not len(p["label"]) > 0: + alab = p["CL"] + else: + alab = p["label"] + aninput = gxtp.DataParam( + newname, + optional=False, + label=alab, + help=p["help"], + format=newfmt, + multiple=False, + num_dashes=ndash, + ) + aninput.positional = self.is_positional + if self.is_positional: + if p["origCL"].upper() == "STDIN": + aninput.positional = 9999998 + aninput.command_line_override = "< $%s" % newname + else: + aninput.positional = int(p["origCL"]) + aninput.command_line_override = "$%s" % newname + if reps: + repe = gxtp.Repeat( + name=f"R_{newname}", title=f"Add as many {alab} as needed" + ) + repe.append(aninput) + self.tinputs.append(repe) + tparm = gxtp.TestRepeat(name=f"R_{newname}") + tparm2 = gxtp.TestParam(newname, value="%s_sample" % newname) + tparm.append(tparm2) + self.testparam.append(tparm) + else: + self.tinputs.append(aninput) + tparm = gxtp.TestParam(newname, value="%s_sample" % newname) + self.testparam.append(tparm) + for p in self.addpar: + newname = p["name"] + newval = p["value"] + newlabel = p["label"] + newhelp = p["help"] + newtype = p["type"] + newcl = p["CL"] + oldcl = p["origCL"] + reps = p["repeat"] == "1" + if not len(newlabel) > 0: + newlabel = newname + ndash = self.getNdash(newname) + if newtype == "text": + aparm = gxtp.TextParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "integer": + aparm = gxtp.IntegerParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "float": + aparm = gxtp.FloatParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "boolean": + aparm = gxtp.BooleanParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + else: + raise ValueError( + 'Unrecognised parameter type "%s" for\ + additional parameter %s in makeXML' + % (newtype, newname) + ) + aparm.positional = self.is_positional + if self.is_positional: + aparm.positional = int(oldcl) + if reps: + repe = gxtp.Repeat( + name=f"R_{newname}", title=f"Add as many {newlabel} as needed" + ) + repe.append(aparm) + self.tinputs.append(repe) + tparm = gxtp.TestRepeat(name=f"R_{newname}") + tparm2 = gxtp.TestParam(newname, value=newval) + tparm.append(tparm2) + self.testparam.append(tparm) + else: + self.tinputs.append(aparm) + tparm = gxtp.TestParam(newname, value=newval) + self.testparam.append(tparm) + for p in self.selpar: + newname = p["name"] + newval = p["value"] + newlabel = p["label"] + newhelp = p["help"] + newtype = p["type"] + newcl = p["CL"] + if not len(newlabel) > 0: + newlabel = newname + ndash = self.getNdash(newname) + if newtype == "selecttext": + newtext = p["texts"] + aparm = gxtp.SelectParam( + newname, + label=newlabel, + help=newhelp, + num_dashes=ndash, + ) + for i in range(len(newval)): + anopt = gxtp.SelectOption( + value=newval[i], + text=newtext[i], + ) + aparm.append(anopt) + aparm.positional = self.is_positional + if self.is_positional: + aparm.positional = int(newcl) + self.tinputs.append(aparm) + tparm = gxtp.TestParam(newname, value=newval) + self.testparam.append(tparm) + else: + raise ValueError( + 'Unrecognised parameter type "%s" for\ + selecttext parameter %s in makeXML' + % (newtype, newname) + ) + for p in self.collections: + newkind = p["kind"] + newname = p["name"] + newlabel = p["label"] + newdisc = p["discover"] + collect = gxtp.OutputCollection(newname, label=newlabel, type=newkind) + disc = gxtp.DiscoverDatasets( + pattern=newdisc, directory=f"{newname}", visible="false" + ) + collect.append(disc) + self.toutputs.append(collect) + try: + tparm = gxtp.TestOutputCollection(newname) # broken until PR merged. + self.testparam.append(tparm) + except Exception: + print( + "#### WARNING: Galaxyxml version does not have the PR merged yet - tests for collections must be over-ridden until then!" + ) + + def doNoXMLparam(self): + """filter style package - stdin to stdout""" + if len(self.infiles) > 0: + alab = self.infiles[0]["label"] + if len(alab) == 0: + alab = self.infiles[0]["infilename"] + max1s = ( + "Maximum one input if parampass is 0 but multiple input files supplied - %s" + % str(self.infiles) + ) + assert len(self.infiles) == 1, max1s + newname = self.infiles[0]["infilename"] + aninput = gxtp.DataParam( + newname, + optional=False, + label=alab, + help=self.infiles[0]["help"], + format=self.infiles[0]["format"], + multiple=False, + num_dashes=0, + ) + aninput.command_line_override = "< $%s" % newname + aninput.positional = True + self.tinputs.append(aninput) + tp = gxtp.TestParam(name=newname, value="%s_sample" % newname) + self.testparam.append(tp) + if len(self.outfiles) > 0: + newname = self.outfiles[0]["name"] + newfmt = self.outfiles[0]["format"] + anout = gxtp.OutputData(newname, format=newfmt, num_dashes=0) + anout.command_line_override = "> $%s" % newname + anout.positional = self.is_positional + self.toutputs.append(anout) + tp = gxtp.TestOutput(name=newname, value="%s_sample" % newname) + self.testparam.append(tp) + + def makeXML(self): # noqa + """ + Create a Galaxy xml tool wrapper for the new script + Uses galaxyhtml + Hmmm. How to get the command line into correct order... + """ + if self.command_override: + self.newtool.command_override = self.command_override # config file + else: + self.newtool.command_override = self.xmlcl + cite = gxtp.Citations() + acite = gxtp.Citation(type="doi", value="10.1093/bioinformatics/bts573") + cite.append(acite) + self.newtool.citations = cite + safertext = "" + if self.args.help_text: + helptext = open(self.args.help_text, "r").readlines() + safertext = "\n".join([cheetah_escape(x) for x in helptext]) + if len(safertext.strip()) == 0: + safertext = ( + "Ask the tool author (%s) to rebuild with help text please\n" + % (self.args.user_email) + ) + if self.args.script_path: + if len(safertext) > 0: + safertext = safertext + "\n\n------\n" # transition allowed! + scr = [x for x in self.spacedScript if x.strip() > ""] + scr.insert(0, "\n\nScript::\n") + if len(scr) > 300: + scr = ( + scr[:100] + + [" >300 lines - stuff deleted", " ......"] + + scr[-100:] + ) + scr.append("\n") + safertext = safertext + "\n".join(scr) + self.newtool.help = safertext + self.newtool.version_command = f'echo "{self.args.tool_version}"' + std = gxtp.Stdios() + std1 = gxtp.Stdio() + std.append(std1) + self.newtool.stdios = std + requirements = gxtp.Requirements() + self.condaenv = [] + if self.args.packages: + try: + for d in self.args.packages.split(","): + ver = None + packg = None + d = d.replace("==", ":") + d = d.replace("=", ":") + if ":" in d: + packg, ver = d.split(":") + ver = ver.strip() + packg = packg.strip() + else: + packg = d.strip() + ver = None + if ver == "": + ver = None + if packg: + requirements.append( + gxtp.Requirement("package", packg.strip(), ver) + ) + self.condaenv.append(d) + except Exception: + print( + "### malformed packages string supplied - cannot parse =", + self.args.packages, + ) + sys.exit(2) + self.newtool.requirements = requirements + if self.args.parampass == "0": + self.doNoXMLparam() + else: + self.doXMLparam() + self.newtool.outputs = self.toutputs + self.newtool.inputs = self.tinputs + if self.args.script_path: + configfiles = gxtp.Configfiles() + configfiles.append( + gxtp.Configfile(name="runme", text="\n".join(self.escapedScript)) + ) + self.newtool.configfiles = configfiles + tests = gxtp.Tests() + test_a = gxtp.Test() + for tp in self.testparam: + test_a.append(tp) + tests.append(test_a) + self.newtool.tests = tests + self.newtool.add_comment( + "Created by %s at %s using the Galaxy Tool Factory." + % (self.args.user_email, timenow()) + ) + self.newtool.add_comment("Source in git at: %s" % (toolFactoryURL)) + exml0 = self.newtool.export() + exml = exml0.replace(FAKEEXE, "") # temporary work around until PR accepted + if ( + self.test_override + ): # cannot do this inside galaxyxml as it expects lxml objects for tests + part1 = exml.split("<tests>")[0] + part2 = exml.split("</tests>")[1] + fixed = "%s\n%s\n%s" % (part1, "\n".join(self.test_override), part2) + exml = fixed + with open("%s.xml" % self.tool_name, "w") as xf: + xf.write(exml) + xf.write("\n") + # galaxy history item + + def writeShedyml(self): + """for planemo""" + yuser = self.args.user_email.split("@")[0] + yfname = os.path.join(self.tooloutdir, ".shed.yml") + yamlf = open(yfname, "w") + odict = { + "name": self.tool_name, + "owner": yuser, + "type": "unrestricted", + "description": self.args.tool_desc, + "synopsis": self.args.tool_desc, + "category": "TF Generated Tools", + } + yaml.dump(odict, yamlf, allow_unicode=True) + yamlf.close() + + def makeTool(self): + """write xmls and input samples into place""" + if self.args.parampass == 0: + self.doNoXMLparam() + else: + self.makeXML() + if self.args.script_path: + stname = os.path.join(self.tooloutdir, self.sfile) + if not os.path.exists(stname): + shutil.copyfile(self.sfile, stname) + xreal = "%s.xml" % self.tool_name + xout = os.path.join(self.tooloutdir, xreal) + shutil.copyfile(xreal, xout) + xout = os.path.join(self.repdir, xreal) + shutil.copyfile(xreal, xout) + for p in self.infiles: + pth = p["name"] + dest = os.path.join(self.testdir, "%s_sample" % p["infilename"]) + shutil.copyfile(pth, dest) + dest = os.path.join( + self.repdir, "%s_sample.%s" % (p["infilename"], p["format"]) + ) + shutil.copyfile(pth, dest) + dest = os.path.join(self.local_tools, self.tool_name) + shutil.copytree(self.tooloutdir,dest, dirs_exist_ok=True) + + def makeToolTar(self, report_fail=False): + """move outputs into test-data and prepare the tarball""" + excludeme = "_planemo_test_report.html" + + def exclude_function(tarinfo): + filename = tarinfo.name + return None if filename.endswith(excludeme) else tarinfo + + for p in self.outfiles: + oname = p["name"] + tdest = os.path.join(self.testdir, "%s_sample" % oname) + src = os.path.join(self.testdir, oname) + if not os.path.isfile(tdest): + if os.path.isfile(src): + shutil.copyfile(src, tdest) + dest = os.path.join(self.repdir, "%s.sample.%s" % (oname,p['format'])) + shutil.copyfile(src, dest) + else: + if report_fail: + print( + "###Tool may have failed - output file %s not found in testdir after planemo run %s." + % (tdest, self.testdir) + ) + tf = tarfile.open(self.newtarpath, "w:gz") + tf.add( + name=self.tooloutdir, + arcname=self.tool_name, + filter=exclude_function, + ) + shutil.copy(self.newtarpath, os.path.join(self.tooloutdir, f"{self.tool_name}_untested_toolshed.gz")) + tf.close() + + + def planemo_test_update(self): + """planemo is a requirement so is available for testing + """ + xreal = "%s.xml" % self.tool_name + tool_test_path = os.path.join( + self.repdir, f"{self.tool_name}_planemo_test_report.html" + ) + if os.path.exists(self.tlog): + tout = open(self.tlog, "a") + else: + tout = open(self.tlog, "w") + cll = [ + "planemo", + "test", + "--conda_auto_init", + "--biocontainers", + "--test_data", + os.path.abspath(self.testdir), + "--test_output", + os.path.abspath(tool_test_path), + "--galaxy_root", + self.args.galaxy_root, + "--update_test_data", + os.path.abspath(xreal), + ] + p = subprocess.run( + cll, + shell=False, + cwd=self.tooloutdir, + stderr=tout, + stdout=tout, + ) + tout.close() + return p.returncode + + + def update_toolconf(self ): + + def sortchildrenby(parent, attr): + parent[:] = sorted(parent, key=lambda child: child.get(attr)) + + tcpath = os.path.join(self.args.galaxy_root,'config/local_tool_conf.xml') + xmlfile = os.path.join(self.local_tools, self.tool_name, '%s.xml' % self.tool_name) + parser = ET.XMLParser(remove_blank_text=True) + tree = ET.parse(tcpath, parser) + root = tree.getroot() + hasTF = False + e = root.findall("section") + if len(e) > 0: + hasTF = True + TFsection = e[0] + if not hasTF: + TFsection = ET.Element("section", {"id":"localtools", "name":"Local Tools"}) + root.insert(0, TFsection) # at the top! + our_tools = TFsection.findall("tool") + conf_tools = [x.attrib["file"] for x in our_tools] + if xmlfile not in conf_tools: # new + ET.SubElement(TFsection, "tool", {"file": xmlfile}) + sortchildrenby(TFsection,"file") + tree.write(tcpath, pretty_print=True) + + + + + + + def shedLoad(self): + """ + use bioblend to create new repository + or update existing + + """ + if os.path.exists(self.tlog): + sto = open(self.tlog, "a") + else: + sto = open(self.tlog, "w") + + ts = toolshed.ToolShedInstance( + url=self.args.toolshed_url, + key=self.args.toolshed_api_key, + verify=False, + ) + repos = ts.repositories.get_repositories() + rnames = [x.get("name", "?") for x in repos] + rids = [x.get("id", "?") for x in repos] + tfcat = "ToolFactory generated tools" + if self.tool_name not in rnames: + tscat = ts.categories.get_categories() + cnames = [x.get("name", "?").strip() for x in tscat] + cids = [x.get("id", "?") for x in tscat] + catID = None + if tfcat.strip() in cnames: + ci = cnames.index(tfcat) + catID = cids[ci] + res = ts.repositories.create_repository( + name=self.args.tool_name, + synopsis="Synopsis:%s" % self.args.tool_desc, + description=self.args.tool_desc, + type="unrestricted", + remote_repository_url=self.args.toolshed_url, + homepage_url=None, + category_ids=catID, + ) + tid = res.get("id", None) + sto.write(f"#create_repository {self.args.tool_name} tid={tid} res={res}\n") + else: + i = rnames.index(self.tool_name) + tid = rids[i] + try: + res = ts.repositories.update_repository( + id=tid, tar_ball_path=self.newtarpath, commit_message=None + ) + sto.write(f"#update res id {id} ={res}\n") + except ConnectionError: + sto.write( + "####### Is the toolshed running and the API key correct? Bioblend shed upload failed\n" + ) + sto.close() + + def eph_galaxy_load(self): + """ + use ephemeris to load the new tool from the local toolshed after planemo uploads it + """ + if os.path.exists(self.tlog): + tout = open(self.tlog, "a") + else: + tout = open(self.tlog, "w") + cll = [ + "shed-tools", + "install", + "-g", + self.args.galaxy_url, + "--latest", + "-a", + self.args.galaxy_api_key, + "--name", + self.tool_name, + "--owner", + "fubar", + "--toolshed", + self.args.toolshed_url, + "--section_label", + "ToolFactory", + ] + tout.write("running\n%s\n" % " ".join(cll)) + subp = subprocess.run( + cll, + env=self.ourenv, + cwd=self.ourcwd, + shell=False, + stderr=tout, + stdout=tout, + ) + tout.write( + "installed %s - got retcode %d\n" % (self.tool_name, subp.returncode) + ) + tout.close() + return subp.returncode + + def planemo_biodocker_test(self): + """planemo currently leaks dependencies if used in the same container and gets unhappy after a + first successful run. https://github.com/galaxyproject/planemo/issues/1078#issuecomment-731476930 + + Docker biocontainer has planemo with caches filled to save repeated downloads + + + """ + + def prun(container, tout, cl, user="biodocker"): + rlog = container.exec_run(cl, user=user) + slogl = str(rlog).split("\\n") + slog = "\n".join(slogl) + tout.write(f"## got rlog {slog} from {cl}\n") + + if os.path.exists(self.tlog): + tout = open(self.tlog, "a") + else: + tout = open(self.tlog, "w") + planemoimage = "quay.io/fubar2/planemo-biocontainer" + xreal = "%s.xml" % self.tool_name + repname = f"{self.tool_name}_planemo_test_report.html" + ptestrep_path = os.path.join(self.repdir, repname) + client = docker.from_env() + tvol = client.volumes.create() + tvolname = tvol.name + destdir = "/toolfactory/ptest" + imrep = os.path.join(destdir, repname) + # need to keep the container running so keep it open with sleep + # will stop and destroy it when we are done + container = client.containers.run( + planemoimage, + "sleep 120m", + detach=True, + user="biodocker", + volumes={f"{tvolname}": {"bind": "/toolfactory", "mode": "rw"}}, + ) + cl = f"mkdir -p {destdir}" + prun(container, tout, cl, user="root") + # that's how hard it is to get root on a biodocker container :( + cl = f"rm -rf {destdir}/*" + prun(container, tout, cl, user="root") + ptestpath = os.path.join(destdir, "tfout", xreal) + self.copy_to_container(self.tooloutdir, destdir, container) + cl = "chown -R biodocker /toolfactory" + prun(container, tout, cl, user="root") + _ = container.exec_run(f"ls -la {destdir}") + ptestcl = f"planemo test --test_output {imrep} --update_test_data --no_cleanup --test_data {destdir}/tfout/test-data --galaxy_root /home/biodocker/galaxy-central {ptestpath}" + try: + _ = container.exec_run(ptestcl) + # fails because test outputs missing but updates the test-data directory + except Exception: + e = sys.exc_info()[0] + tout.write(f"#### error: {e} from {ptestcl}\n") + cl = f"planemo test --test_output {imrep} --no_cleanup --test_data {destdir}/tfout/test-data --galaxy_root /home/biodocker/galaxy-central {ptestpath}" + try: + prun(container, tout, cl) + except Exception: + e = sys.exc_info()[0] + tout.write(f"#### error: {e} from {ptestcl}\n") + testouts = tempfile.mkdtemp(suffix=None, prefix="tftemp", dir=".") + self.copy_from_container(destdir, testouts, container) + src = os.path.join(testouts, "ptest") + if os.path.isdir(src): + shutil.copytree(src, ".", dirs_exist_ok=True) + src = repname + if os.path.isfile(repname): + shutil.copyfile(src, ptestrep_path) + else: + tout.write(f"No output from run to shutil.copytree in {src}\n") + tout.close() + container.stop() + container.remove() + tvol.remove() + shutil.rmtree(testouts) # leave for debugging + + + # def run(self): + # """ + # scripts must be small enough not to fill the pipe! + # """ + # if self.treatbashSpecial and self.opts.interpreter in ['bash','sh']: + # retval = self.runBash() + # else: + # if self.opts.output_dir: + # ste = open(self.elog,'w') + # sto = open(self.tlog,'w') + # sto.write('## Toolfactory generated command line = %s\n' % ' '.join(self.cl)) + # sto.flush() + # p = subprocess.Popen(self.cl,shell=False,stdout=sto,stderr=ste,stdin=subprocess.PIPE,cwd=self.opts.output_dir) + # else: + # p = subprocess.Popen(self.cl,shell=False,stdin=subprocess.PIPE) + # p.stdin.write(self.script) + # p.stdin.close() + # retval = p.wait() + # if self.opts.output_dir: + # sto.close() + # ste.close() + # err = open(self.elog,'r').read() + # if retval <> 0 and err: # problem + # print >> sys.stderr, '## error code %d returned with:\n%s' % (retval,err) + # if self.opts.make_HTML: + # self.makeHtml() + # return retval + + # def runBash(self): + # """ + # cannot use - for bash so use self.sfile + # """ + # if self.opts.output_dir: + # s = '## Toolfactory generated command line = %s\n' % ' '.join(self.cl) + # sto = open(self.tlog,'w') + # sto.write(s) + # sto.flush() + # p = subprocess.Popen(self.cl,shell=False,stdout=sto,stderr=sto,cwd=self.opts.output_dir) + # else: + # p = subprocess.Popen(self.cl,shell=False) + # retval = p.wait() + # if self.opts.output_dir: + # sto.close() + # if self.opts.make_HTML: + # self.makeHtml() + # return retval + + # def make_conda_env(self, dep_list): + # """ +# (venv) galaxy@ross-newgrt:/evol/galaxy$ mulled-hash bioblend=0.17.0,galaxyxml=0.4.14 +# mulled-v2-37438395e15c3d0bed4e02d66d5b05ca3d18b389:1d0b008b65909163243b3fdddd9aa20605f8a005 + +# conda create -n myenv python=3.9 scipy=0.17.3 astroid babel + + + # """ + # dep_list.sort() + # self.env_name = '-'.join(dep_list) + # for e in self.xmlcl + + + # for e in self.xclsuffix: + # # xappendme = ["999", p["infilename"], "< $%s" % p["infilename"]] + # else: + # xappendme = [p["CL"], "$%s" % p["infilename"], ""] + # xclsuffix.append(xappendme) + # if os.path.exists(self.tlog): + # tout = open(self.tlog, "a") + # else: + # tout = open(self.tlog, "w") + # cli = ["conda", "create", "-n", self.env_name, ' '.join(dep_list)] + # p = subprocess.run( + # cll, + # shell=False, + # cwd=self.tooloutdir, + # stderr=tout, + # stdout=tout, + # ) + # cli = ["conda", "activate", self.env_name, " && "] + # cli.append(run_cmd) + # tout.close() + +def main(): + """ + This is a Galaxy wrapper. + It expects to be called by a special purpose tool.xml + + """ + parser = argparse.ArgumentParser() + a = parser.add_argument + a("--script_path", default=None) + a("--history_test", default=None) + a("--cl_user_suffix", default=None) + a("--sysexe", default=None) + a("--packages", default=None) + a("--tool_name", default="newtool") + a("--tool_dir", default=None) + a("--input_files", default=[], action="append") + a("--output_files", default=[], action="append") + a("--user_email", default="Unknown") + a("--bad_user", default=None) + a("--help_text", default=None) + a("--tool_desc", default=None) + a("--tool_version", default="0.01") + a("--citations", default=None) + a("--command_override", default=None) + a("--test_override", default=None) + a("--additional_parameters", action="append", default=[]) + a("--selecttext_parameters", action="append", default=[]) + a("--edit_additional_parameters", action="store_true", default=False) + a("--parampass", default="positional") + a("--tfout", default="./tfout") + a("--galaxy_root", default="/galaxy-central") + a("--galaxy_venv", default="/galaxy_venv") + a("--collection", action="append", default=[]) + a("--include_tests", default=False, action="store_true") + a("--install_flag", action = "store_true", default=False) + a("--admin_only", default=True, action="store_true") + a("--untested_tool_out", default=None) + a("--local_tools", default="tools") # relative to $__root_dir__ + a("--tool_conf_path", default="config/tool_conf.xml") # relative to $__root_dir__ + args = parser.parse_args() + if args.admin_only: + assert not args.bad_user, ( + 'UNAUTHORISED: %s is NOT authorized to use this tool until Galaxy \ +admin adds %s to "admin_users" in the galaxy.yml Galaxy configuration file' + % (args.bad_user, args.bad_user) + ) + assert args.tool_name, "## This ToolFactory cannot build a tool without a tool name. Please supply one." + tf = Tool_Factory(args) + tf.writeShedyml() + tf.makeTool() + tf.planemo_test_update() + tf.makeToolTar() + tf.update_toolconf() + + +if __name__ == "__main__": + main()
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tacrev/test-data/tacrev_reversed_output_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1210 @@ +)(niam +:"__niam__" == __eman__ fi + + +)(fnocloot_etadpu.ft +)(raTlooTekam.ft +)(etadpu_tset_omenalp.ft +)(looTekam.ft +)(lmydehSetirw.ft +)sgra(yrotcaF_looT = ft +".eno ylppus esaelP .eman loot a tuohtiw loot a dliub tonnac yrotcaFlooT sihT ##" ,eman_loot.sgra tressa +) +)resu_dab.sgra ,resu_dab.sgra( % +'elif noitarugifnoc yxalaG lmy.yxalag eht ni "sresu_nimda" ot s% sdda nimda +\ yxalaG litnu loot siht esu ot dezirohtua TON si s% :DESIROHTUANU' +( ,resu_dab.sgra ton tressa +:ylno_nimda.sgra fi +)(sgra_esrap.resrap = sgra +__rid_toor__$ ot evitaler # )"lmx.fnoc_loot/gifnoc"=tluafed ,"htap_fnoc_loot--"(a +__rid_toor__$ ot evitaler # )"sloot"=tluafed ,"sloot_lacol--"(a +)enoN=tluafed ,"tuo_loot_detsetnu--"(a +)"eurt_erots"=noitca ,eurT=tluafed ,"ylno_nimda--"(a +)eslaF=tluafed ,"eurt_erots" = noitca ,"galf_llatsni--"(a +)"eurt_erots"=noitca ,eslaF=tluafed ,"stset_edulcni--"(a +)][=tluafed ,"dneppa"=noitca ,"noitcelloc--"(a +)"vnev_yxalag/"=tluafed ,"vnev_yxalag--"(a +)"lartnec-yxalag/"=tluafed ,"toor_yxalag--"(a +)"tuoft/."=tluafed ,"tuoft--"(a +)"lanoitisop"=tluafed ,"ssapmarap--"(a +)eslaF=tluafed ,"eurt_erots"=noitca ,"sretemarap_lanoitidda_tide--"(a +)][=tluafed ,"dneppa"=noitca ,"sretemarap_txettceles--"(a +)][=tluafed ,"dneppa"=noitca ,"sretemarap_lanoitidda--"(a +)enoN=tluafed ,"edirrevo_tset--"(a +)enoN=tluafed ,"edirrevo_dnammoc--"(a +)enoN=tluafed ,"snoitatic--"(a +)"10.0"=tluafed ,"noisrev_loot--"(a +)enoN=tluafed ,"csed_loot--"(a +)enoN=tluafed ,"txet_pleh--"(a +)enoN=tluafed ,"resu_dab--"(a +)"nwonknU"=tluafed ,"liame_resu--"(a +)"dneppa"=noitca ,][=tluafed ,"selif_tuptuo--"(a +)"dneppa"=noitca ,][=tluafed ,"selif_tupni--"(a +)enoN=tluafed ,"rid_loot--"(a +)"lootwen"=tluafed ,"eman_loot--"(a +)enoN=tluafed ,"segakcap--"(a +)enoN=tluafed ,"exesys--"(a +)enoN=tluafed ,"xiffus_resu_lc--"(a +)enoN=tluafed ,"tset_yrotsih--"(a +)enoN=tluafed ,"htap_tpircs--"(a +tnemugra_dda.resrap = a +)(resraPtnemugrA.esrapgra = resrap +""" + +lmx.loot esoprup laiceps a yb dellac eb ot stcepxe tI +.repparw yxalaG a si sihT +""" +:)(niam fed + +)(esolc.tuot # +)dmc_nur(dneppa.ilc # +]" && " ,eman_vne.fles ,"etavitca" ,"adnoc"[ = ilc # +) # +,tuot=tuodts # +,tuot=rredts # +,ridtuoloot.fles=dwc # +,eslaF=llehs # +,llc # +(nur.ssecorpbus = p # +])tsil_ped(nioj.' ' ,eman_vne.fles ,"n-" ,"etaerc" ,"adnoc"[ = ilc # +)"w" ,golt.fles(nepo = tuot # +:esle # +)"a" ,golt.fles(nepo = tuot # +:)golt.fles(stsixe.htap.so fi # +)emdneppax(dneppa.xiffuslcx # +]"" ,]"emanelifni"[p % "s%$" ,]"LC"[p[ = emdneppax # +:esle # +]]"emanelifni"[p % "s%$ <" ,]"emanelifni"[p ,"999"[ = emdneppax # # +:xiffuslcx.fles ni e rof # + ++ lclmx.fles ni e rof # +)tsil_ped(nioj.'-' = eman_vne.fles # +)(tros.tsil_ped # +""" # + + +lebab diortsa 3.71.0=ypics 9.3=nohtyp vneym n- etaerc adnoc # + +500a8f50602aa9ddddf3b34236190956b800b0d1:983b81d3ac50b5d66d20e4deb0d3c51e59383473-2v-dellum # +41.4.0=lmxyxalag,0.71.0=dnelboib hsah-dellum $yxalag/love/:trgwen-ssor@yxalag )vnev( # +""" # +:)tsil_ped ,fles(vne_adnoc_ekam fed # + +lavter nruter # +)(lmtHekam.fles # +:LMTH_ekam.stpo.fles fi # +)(esolc.ots # +:rid_tuptuo.stpo.fles fi # +)(tiaw.p = lavter # +)eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +:esle # +)rid_tuptuo.stpo.fles=dwc,ots=rredts,ots=tuodts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +)(hsulf.ots # +)s(etirw.ots # +)'w',golt.fles(nepo = ots # +)lc.fles(nioj.' ' % 'n\s% = enil dnammoc detareneg yrotcaflooT ##' = s # +:rid_tuptuo.stpo.fles fi # +""" # +elifs.fles esu os hsab rof - esu tonnac # +""" # +:)fles(hsaBnur fed # + +lavter nruter # +)(lmtHekam.fles # +:LMTH_ekam.stpo.fles fi # +)rre,lavter( % 's%n\:htiw denruter d% edoc rorre ##' ,rredts.sys >> tnirp # +melborp # :rre dna 0 >< lavter fi # +)(daer.)'r',gole.fles(nepo = rre # +)(esolc.ets # +)(esolc.ots # +:rid_tuptuo.stpo.fles fi # +)(tiaw.p = lavter # +)(esolc.nidts.p # +)tpircs.fles(etirw.nidts.p # +)EPIP.ssecorpbus=nidts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +:esle # +)rid_tuptuo.stpo.fles=dwc,EPIP.ssecorpbus=nidts,ets=rredts,ots=tuodts,eslaF=llehs,lc.fles(nepoP.ssecorpbus = p # +)(hsulf.ots # +))lc.fles(nioj.' ' % 'n\s% = enil dnammoc detareneg yrotcaflooT ##'(etirw.ots # +)'w',golt.fles(nepo = ots # +)'w',gole.fles(nepo = ets # +:rid_tuptuo.stpo.fles fi # +:esle # +)(hsaBnur.fles = lavter # +:]'hs','hsab'[ ni reterpretni.stpo.fles dna laicepShsabtaert.fles fi # +""" # +!epip eht llif ot ton hguone llams eb tsum stpircs # +""" # +:)fles(nur fed # + + +gniggubed rof evael # )stuotset(eertmr.lituhs +)(evomer.lovt +)(evomer.reniatnoc +)(pots.reniatnoc +)(esolc.tuot +)"n\}crs{ ni eertypoc.lituhs ot nur morf tuptuo oN"f(etirw.tuot +:esle +)htap_pertsetp ,crs(elifypoc.lituhs +:)emanper(elifsi.htap.so fi +emanper = crs +)eurT=ko_tsixe_srid ,"." ,crs(eertypoc.lituhs +:)crs(ridsi.htap.so fi +)"tsetp" ,stuotset(nioj.htap.so = crs +)reniatnoc ,stuotset ,ridtsed(reniatnoc_morf_ypoc.fles +)"."=rid ,"pmetft"=xiferp ,enoN=xiffus(pmetdkm.elifpmet = stuotset +)"n\}lctsetp{ morf }e{ :rorre ####"f(etirw.tuot +]0[)(ofni_cxe.sys = e +:noitpecxE tpecxe +)lc ,tuot ,reniatnoc(nurp +:yrt +"}htaptsetp{ lartnec-yxalag/rekcodoib/emoh/ toor_yxalag-- atad-tset/tuoft/}ridtsed{ atad_tset-- punaelc_on-- }permi{ tuptuo_tset-- tset omenalp"f = lc +)"n\}lctsetp{ morf }e{ :rorre ####"f(etirw.tuot +]0[)(ofni_cxe.sys = e +:noitpecxE tpecxe +yrotcerid atad-tset eht setadpu tub gnissim stuptuo tset esuaceb sliaf # +)lctsetp(nur_cexe.reniatnoc = _ +:yrt +"}htaptsetp{ lartnec-yxalag/rekcodoib/emoh/ toor_yxalag-- atad-tset/tuoft/}ridtsed{ atad_tset-- punaelc_on-- atad_tset_etadpu-- }permi{ tuptuo_tset-- tset omenalp"f = lctsetp +)"}ridtsed{ al- sl"f(nur_cexe.reniatnoc = _ +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +"yrotcafloot/ rekcodoib R- nwohc" = lc +)reniatnoc ,ridtsed ,ridtuoloot.fles(reniatnoc_ot_ypoc.fles +)laerx ,"tuoft" ,ridtsed(nioj.htap.so = htaptsetp +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +"*/}ridtsed{ fr- mr"f = lc +(: reniatnoc rekcodoib a no toor teg ot si ti drah woh s'taht # +)"toor"=resu ,lc ,tuot ,reniatnoc(nurp +"}ridtsed{ p- ridkm"f = lc +) +,}}"wr" :"edom" ,"yrotcafloot/" :"dnib"{ :"}emanlovt{"f{=semulov +,"rekcodoib"=resu +,eurT=hcated +,"m021 peels" +,egamiomenalp +(nur.sreniatnoc.tneilc = reniatnoc +enod era ew nehw ti yortsed dna pots lliw # +peels htiw nepo ti peek os gninnur reniatnoc eht peek ot deen # +)emanper ,ridtsed(nioj.htap.so = permi +"tsetp/yrotcafloot/" = ridtsed +eman.lovt = emanlovt +)(etaerc.semulov.tneilc = lovt +)(vne_morf.rekcod = tneilc +)emanper ,ridper.fles(nioj.htap.so = htap_pertsetp +"lmth.troper_tset_omenalp_}eman_loot.fles{"f = emanper +eman_loot.fles % "lmx.s%" = laerx +"reniatnocoib-omenalp/2rabuf/oi.yauq" = egamiomenalp +)"w" ,golt.fles(nepo = tuot +:esle +)"a" ,golt.fles(nepo = tuot +:)golt.fles(stsixe.htap.so fi + +)"n\}lc{ morf }gols{ golr tog ##"f(etirw.tuot +)lgols(nioj."n\" = gols +)"n\\"(tilps.)golr(rts = lgols +)resu=resu ,lc(nur_cexe.reniatnoc = golr +:)"rekcodoib"=resu ,lc ,tuot ,reniatnoc(nurp fed + +""" + + +sdaolnwod detaeper evas ot dellif sehcac htiw omenalp sah reniatnocoib rekcoD + +039674137-tnemmoceussi#8701/seussi/omenalp/tcejorpyxalag/moc.buhtig//:sptth .nur lufsseccus tsrif +a retfa yppahnu steg dna reniatnoc emas eht ni desu fi seicnedneped skael yltnerruc omenalp""" +:)fles(tset_rekcodoib_omenalp fed + +edocnruter.pbus nruter +)(esolc.tuot +) +)edocnruter.pbus ,eman_loot.fles( % "n\d% edocter tog - s% dellatsni" +(etirw.tuot +) +,tuot=tuodts +,tuot=rredts +,eslaF=llehs +,dwcruo.fles=dwc +,vneruo.fles=vne +,llc +(nur.ssecorpbus = pbus +))llc(nioj." " % "n\s%n\gninnur"(etirw.tuot +] +,"yrotcaFlooT" +,"lebal_noitces--" +,lru_dehsloot.sgra.fles +,"dehsloot--" +,"rabuf" +,"renwo--" +,eman_loot.fles +,"eman--" +,yek_ipa_yxalag.sgra.fles +,"a-" +,"tsetal--" +,lru_yxalag.sgra.fles +,"g-" +,"llatsni" +,"sloot-dehs" +[ = llc +)"w" ,golt.fles(nepo = tuot +:esle +)"a" ,golt.fles(nepo = tuot +:)golt.fles(stsixe.htap.so fi +""" +ti sdaolpu omenalp retfa dehsloot lacol eht morf loot wen eht daol ot siremehpe esu +""" +:)fles(daol_yxalag_hpe fed + +)(esolc.ots +) +"n\deliaf daolpu dehs dnelboiB ?tcerroc yek IPA eht dna gninnur dehsloot eht sI #######" +(etirw.ots +:rorrEnoitcennoC tpecxe +)"n\}ser{= }di{ di ser etadpu#"f(etirw.ots +) +enoN=egassem_timmoc ,htapratwen.fles=htap_llab_rat ,dit=di +(yrotisoper_etadpu.seirotisoper.st = ser +:yrt +]i[sdir = dit +)eman_loot.fles(xedni.semanr = i +:esle +)"n\}ser{=ser }dit{=dit }eman_loot.sgra.fles{ yrotisoper_etaerc#"f(etirw.ots +)enoN ,"di"(teg.ser = dit +) +,DItac=sdi_yrogetac +,enoN=lru_egapemoh +,lru_dehsloot.sgra.fles=lru_yrotisoper_etomer +,"detcirtsernu"=epyt +,csed_loot.sgra.fles=noitpircsed +,csed_loot.sgra.fles % "s%:sisponyS"=sisponys +,eman_loot.sgra.fles=eman +(yrotisoper_etaerc.seirotisoper.st = ser +]ic[sdic = DItac +)tacft(xedni.semanc = ic +:semanc ni )(pirts.tacft fi +enoN = DItac +]tacst ni x rof )"?" ,"di"(teg.x[ = sdic +]tacst ni x rof )(pirts.)"?" ,"eman"(teg.x[ = semanc +)(seirogetac_teg.seirogetac.st = tacst +:semanr ni ton eman_loot.fles fi +"sloot detareneg yrotcaFlooT" = tacft +]soper ni x rof )"?" ,"di"(teg.x[ = sdir +]soper ni x rof )"?" ,"eman"(teg.x[ = semanr +)(seirotisoper_teg.seirotisoper.st = soper +) +,eslaF=yfirev +,yek_ipa_dehsloot.sgra.fles=yek +,lru_dehsloot.sgra.fles=lru +(ecnatsnIdehSlooT.dehsloot = st + +)"w" ,golt.fles(nepo = ots +:esle +)"a" ,golt.fles(nepo = ots +:)golt.fles(stsixe.htap.so fi +""" + +gnitsixe etadpu ro +yrotisoper wen etaerc ot dnelboib esu +""" +:)fles(daoLdehs fed + + + + + + +)eurT=tnirp_ytterp ,htapct(etirw.eert +)"elif",noitcesFT(ybnerdlihctros +)}eliflmx :"elif"{ ,"loot" ,noitcesFT(tnemelEbuS.TE +wen # :sloot_fnoc ni ton eliflmx fi +]sloot_ruo ni x rof ]"elif"[birtta.x[ = sloot_fnoc +)"loot"(lladnif.noitcesFT = sloot_ruo +!pot eht ta # )noitcesFT ,0(tresni.toor +)}"slooT lacoL":"eman" ,"slootlacol":"di"{ ,"noitces"(tnemelE.TE = noitcesFT +:FTsah ton fi +]0[e = noitcesFT +eurT = FTsah +:0 > )e(nel fi +)"noitces"(lladnif.toor = e +eslaF = FTsah +)(toorteg.eert = toor +)resrap ,htapct(esrap.TE = eert +)eurT=txet_knalb_evomer(resraPLMX.TE = resrap +)eman_loot.fles % 'lmx.s%' ,eman_loot.fles ,sloot_lacol.fles(nioj.htap.so = eliflmx +)'lmx.fnoc_loot_lacol/gifnoc',toor_yxalag.sgra.fles(nioj.htap.so = htapct + +))rtta(teg.dlihc :dlihc adbmal=yek ,tnerap(detros = ]:[tnerap +:)rtta ,tnerap(ybnerdlihctros fed + +:) fles(fnocloot_etadpu fed + + +edocnruter.p nruter +)(esolc.tuot +) +,tuot=tuodts +,tuot=rredts +,ridtuoloot.fles=dwc +,eslaF=llehs +,llc +(nur.ssecorpbus = p +] +,)laerx(htapsba.htap.so +,"atad_tset_etadpu--" +,toor_yxalag.sgra.fles +,"toor_yxalag--" +,)htap_tset_loot(htapsba.htap.so +,"tuptuo_tset--" +,)ridtset.fles(htapsba.htap.so +,"atad_tset--" +,"sreniatnocoib--" +,"tini_otua_adnoc--" +,"tset" +,"omenalp" +[ = llc +)"w" ,golt.fles(nepo = tuot +:esle +)"a" ,golt.fles(nepo = tuot +:)golt.fles(stsixe.htap.so fi +) +"lmth.troper_tset_omenalp_}eman_loot.fles{"f ,ridper.fles +(nioj.htap.so = htap_tset_loot +eman_loot.fles % "lmx.s%" = laerx +""" +gnitset rof elbaliava si os tnemeriuqer a si omenalp""" +:)fles(etadpu_tset_omenalp fed + + +)(esolc.ft +))"zg.dehsloot_detsetnu_}eman_loot.fles{"f ,ridtuoloot.fles(nioj.htap.so ,htapratwen.fles(ypoc.lituhs +) +,noitcnuf_edulcxe=retlif +,eman_loot.fles=emancra +,ridtuoloot.fles=eman +(dda.ft +)"zg:w" ,htapratwen.fles(nepo.elifrat = ft +) +)ridtset.fles ,tsedt( % +".s% nur omenalp retfa ridtset ni dnuof ton s% elif tuptuo - deliaf evah yam looT###" +(tnirp +:liaf_troper fi +:esle +)tsed ,crs(elifypoc.lituhs +))]'tamrof'[p,emano( % "s%.elpmas.s%" ,ridper.fles(nioj.htap.so = tsed +)tsedt ,crs(elifypoc.lituhs +:)crs(elifsi.htap.so fi +:)tsedt(elifsi.htap.so ton fi +)emano ,ridtset.fles(nioj.htap.so = crs +)emano % "elpmas_s%" ,ridtset.fles(nioj.htap.so = tsedt +]"eman"[p = emano +:seliftuo.fles ni p rof + +ofnirat esle )emedulcxe(htiwsdne.emanelif fi enoN nruter +eman.ofnirat = emanelif +:)ofnirat(noitcnuf_edulcxe fed + +"lmth.troper_tset_omenalp_" = emedulcxe +"""llabrat eht eraperp dna atad-tset otni stuptuo evom""" +:)eslaF=liaf_troper ,fles(raTlooTekam fed + +)eurT=ko_tsixe_srid ,tsed,ridtuoloot.fles(eertypoc.lituhs +)eman_loot.fles ,sloot_lacol.fles(nioj.htap.so = tsed +)tsed ,htp(elifypoc.lituhs +) +)]"tamrof"[p ,]"emanelifni"[p( % "s%.elpmas_s%" ,ridper.fles +(nioj.htap.so = tsed +)tsed ,htp(elifypoc.lituhs +)]"emanelifni"[p % "elpmas_s%" ,ridtset.fles(nioj.htap.so = tsed +]"eman"[p = htp +:selifni.fles ni p rof +)tuox ,laerx(elifypoc.lituhs +)laerx ,ridper.fles(nioj.htap.so = tuox +)tuox ,laerx(elifypoc.lituhs +)laerx ,ridtuoloot.fles(nioj.htap.so = tuox +eman_loot.fles % "lmx.s%" = laerx +)emants ,elifs.fles(elifypoc.lituhs +:)emants(stsixe.htap.so ton fi +)elifs.fles ,ridtuoloot.fles(nioj.htap.so = emants +:htap_tpircs.sgra.fles fi +)(LMXekam.fles +:esle +)(marapLMXoNod.fles +:0 == ssapmarap.sgra.fles fi +"""ecalp otni selpmas tupni dna slmx etirw""" +:)fles(looTekam fed + +)(esolc.flmay +)eurT=edocinu_wolla ,flmay ,tcido(pmud.lmay +} +,"slooT detareneG FT" :"yrogetac" +,csed_loot.sgra.fles :"sisponys" +,csed_loot.sgra.fles :"noitpircsed" +,"detcirtsernu" :"epyt" +,resuy :"renwo" +,eman_loot.fles :"eman" +{ = tcido +)"w" ,emanfy(nepo = flmay +)"lmy.dehs." ,ridtuoloot.fles(nioj.htap.so = emanfy +]0[)"@"(tilps.liame_resu.sgra.fles = resuy +"""omenalp rof""" +:)fles(lmydehSetirw fed + +meti yrotsih yxalag # +)"n\"(etirw.fx +)lmxe(etirw.fx +:fx sa )"w" ,eman_loot.fles % "lmx.s%"(nepo htiw +dexif = lmxe +)2trap ,)edirrevo_tset.fles(nioj."n\" ,1trap( % "s%n\s%n\s%" = dexif +]1[)">stset/<"(tilps.lmxe = 2trap +]0[)">stset<"(tilps.lmxe = 1trap +stset rof stcejbo lmxl stcepxe ti sa lmxyxalag edisni siht od tonnac # :) +edirrevo_tset.fles +( fi +detpecca RP litnu dnuora krow yraropmet # )"" ,EXEEKAF(ecalper.0lmxe = lmxe +)(tropxe.lootwen.fles = 0lmxe +))LRUyrotcaFloot( % "s% :ta tig ni ecruoS"(tnemmoc_dda.lootwen.fles +) +))(wonemit ,liame_resu.sgra.fles( % +".yrotcaF looT yxalaG eht gnisu s% ta s% yb detaerC" +(tnemmoc_dda.lootwen.fles +stset = stset.lootwen.fles +)a_tset(dneppa.stset +)pt(dneppa.a_tset +:maraptset.fles ni pt rof +)(tseT.ptxg = a_tset +)(stseT.ptxg = stset +selifgifnoc = selifgifnoc.lootwen.fles +) +))tpircSdepacse.fles(nioj."n\"=txet ,"emnur"=eman(elifgifnoC.ptxg +(dneppa.selifgifnoc +)(selifgifnoC.ptxg = selifgifnoc +:htap_tpircs.sgra.fles fi +stupnit.fles = stupni.lootwen.fles +stuptuot.fles = stuptuo.lootwen.fles +)(marapLMXod.fles +:esle +)(marapLMXoNod.fles +:"0" == ssapmarap.sgra.fles fi +stnemeriuqer = stnemeriuqer.lootwen.fles +)2(tixe.sys +) +,segakcap.sgra.fles +,"= esrap tonnac - deilppus gnirts segakcap demroflam ###" +(tnirp +:noitpecxE tpecxe +)d(dneppa.vneadnoc.fles +) +)rev ,)(pirts.gkcap ,"egakcap"(tnemeriuqeR.ptxg +(dneppa.stnemeriuqer +:gkcap fi +enoN = rev +:"" == rev fi +enoN = rev +)(pirts.d = gkcap +:esle +)(pirts.gkcap = gkcap +)(pirts.rev = rev +)":"(tilps.d = rev ,gkcap +:d ni ":" fi +)":" ,"="(ecalper.d = d +)":" ,"=="(ecalper.d = d +enoN = gkcap +enoN = rev +:)","(tilps.segakcap.sgra.fles ni d rof +:yrt +:segakcap.sgra.fles fi +][ = vneadnoc.fles +)(stnemeriuqeR.ptxg = stnemeriuqer +dts = soidts.lootwen.fles +)1dts(dneppa.dts +)(oidtS.ptxg = 1dts +)(soidtS.ptxg = dts +'"}noisrev_loot.sgra.fles{" ohce'f = dnammoc_noisrev.lootwen.fles +txetrefas = pleh.lootwen.fles +)rcs(nioj."n\" + txetrefas = txetrefas +)"n\"(dneppa.rcs +) +]:001-[rcs + +]"...... " ,"deteled ffuts - senil 003> "[ + +]001:[rcs +( = rcs +:003 > )rcs(nel fi +)"n\::tpircSn\n\" ,0(tresni.rcs +]"" > )(pirts.x fi tpircSdecaps.fles ni x rof x[ = rcs +!dewolla noitisnart # "n\------n\n\" + txetrefas = txetrefas +:0 > )txetrefas(nel fi +:htap_tpircs.sgra.fles fi +) +)liame_resu.sgra.fles( % +"n\esaelp txet pleh htiw dliuber ot )s%( rohtua loot eht ksA" +( = txetrefas +:0 == ))(pirts.txetrefas(nel fi +)]txetpleh ni x rof )x(epacse_hateehc[(nioj."n\" = txetrefas +)(senildaer.)"r" ,txet_pleh.sgra.fles(nepo = txetpleh +:txet_pleh.sgra.fles fi +"" = txetrefas +etic = snoitatic.lootwen.fles +)etica(dneppa.etic +)"375stb/scitamrofnioib/3901.01"=eulav ,"iod"=epyt(noitatiC.ptxg = etica +)(snoitatiC.ptxg = etic +lclmx.fles = edirrevo_dnammoc.lootwen.fles +:esle +elif gifnoc # edirrevo_dnammoc.fles = edirrevo_dnammoc.lootwen.fles +:edirrevo_dnammoc.fles fi +""" +...redro tcerroc otni enil dnammoc eht teg ot woH .mmmH +lmthyxalag sesU +tpircs wen eht rof repparw loot lmx yxalaG a etaerC +""" +aqon # :)fles(LMXekam fed + +)pt(dneppa.maraptset.fles +)emanwen % "elpmas_s%"=eulav ,emanwen=eman(tuptuOtseT.ptxg = pt +)tuona(dneppa.stuptuot.fles +lanoitisop_si.fles = lanoitisop.tuona +emanwen % "s%$ >" = edirrevo_enil_dnammoc.tuona +)0=sehsad_mun ,tmfwen=tamrof ,emanwen(ataDtuptuO.ptxg = tuona +]"tamrof"[]0[seliftuo.fles = tmfwen +]"eman"[]0[seliftuo.fles = emanwen +:0 > )seliftuo.fles(nel fi +)pt(dneppa.maraptset.fles +)emanwen % "elpmas_s%"=eulav ,emanwen=eman(maraPtseT.ptxg = pt +)tupnina(dneppa.stupnit.fles +eurT = lanoitisop.tupnina +emanwen % "s%$ <" = edirrevo_enil_dnammoc.tupnina +) +,0=sehsad_mun +,eslaF=elpitlum +,]"tamrof"[]0[selifni.fles=tamrof +,]"pleh"[]0[selifni.fles=pleh +,bala=lebal +,eslaF=lanoitpo +,emanwen +(maraPataD.ptxg = tupnina +]"emanelifni"[]0[selifni.fles = emanwen +s1xam ,1 == )selifni.fles(nel tressa +) +)selifni.fles(rts % +"s% - deilppus selif tupni elpitlum tub 0 si ssapmarap fi tupni eno mumixaM" +( = s1xam +]"emanelifni"[]0[selifni.fles = bala +:0 == )bala(nel fi +]"lebal"[]0[selifni.fles = bala +:0 > )selifni.fles(nel fi +"""tuodts ot nidts - egakcap elyts retlif""" +:)fles(marapLMXoNod fed + +) +"!neht litnu neddir-revo eb tsum snoitcelloc rof stset - tey degrem RP eht evah ton seod noisrev lmxyxalaG :GNINRAW ####" +(tnirp +:noitpecxE tpecxe +)mrapt(dneppa.maraptset.fles +.degrem RP litnu nekorb # )emanwen(noitcelloCtuptuOtseT.ptxg = mrapt +:yrt +)tcelloc(dneppa.stuptuot.fles +)csid(dneppa.tcelloc +) +"eslaf"=elbisiv ,"}emanwen{"f=yrotcerid ,csidwen=nrettap +(stesataDrevocsiD.ptxg = csid +)dnikwen=epyt ,lebalwen=lebal ,emanwen(noitcelloCtuptuO.ptxg = tcelloc +]"revocsid"[p = csidwen +]"lebal"[p = lebalwen +]"eman"[p = emanwen +]"dnik"[p = dnikwen +:snoitcelloc.fles ni p rof +) +)emanwen ,epytwen( % +'LMXekam ni s% retemarap txettceles +\rof "s%" epyt retemarap desingocernU' +(rorrEeulaV esiar +:esle +)mrapt(dneppa.maraptset.fles +)lavwen=eulav ,emanwen(maraPtseT.ptxg = mrapt +)mrapa(dneppa.stupnit.fles +)lcwen(tni = lanoitisop.mrapa +:lanoitisop_si.fles fi +lanoitisop_si.fles = lanoitisop.mrapa +)tpona(dneppa.mrapa +) +,]i[txetwen=txet +,]i[lavwen=eulav +(noitpOtceleS.ptxg = tpona +:))lavwen(nel(egnar ni i rof +) +,hsadn=sehsad_mun +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPtceleS.ptxg = mrapa +]"stxet"[p = txetwen +:"txettceles" == epytwen fi +)emanwen(hsadNteg.fles = hsadn +emanwen = lebalwen +:0 > )lebalwen(nel ton fi +]"LC"[p = lcwen +]"epyt"[p = epytwen +]"pleh"[p = plehwen +]"lebal"[p = lebalwen +]"eulav"[p = lavwen +]"eman"[p = emanwen +:raples.fles ni p rof +)mrapt(dneppa.maraptset.fles +)lavwen=eulav ,emanwen(maraPtseT.ptxg = mrapt +)mrapa(dneppa.stupnit.fles +:esle +)mrapt(dneppa.maraptset.fles +)2mrapt(dneppa.mrapt +)lavwen=eulav ,emanwen(maraPtseT.ptxg = 2mrapt +)"}emanwen{_R"f=eman(taepeRtseT.ptxg = mrapt +)eper(dneppa.stupnit.fles +)mrapa(dneppa.eper +) +"dedeen sa }lebalwen{ ynam sa ddA"f=eltit ,"}emanwen{_R"f=eman +(taepeR.ptxg = eper +:sper fi +)lcdlo(tni = lanoitisop.mrapa +:lanoitisop_si.fles fi +lanoitisop_si.fles = lanoitisop.mrapa +) +)emanwen ,epytwen( % +'LMXekam ni s% retemarap lanoitidda +\rof "s%" epyt retemarap desingocernU' +(rorrEeulaV esiar +:esle +) +,hsadn=sehsad_mun +,lavwen=eulav +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPnaelooB.ptxg = mrapa +:"naeloob" == epytwen file +) +,hsadn=sehsad_mun +,lavwen=eulav +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPtaolF.ptxg = mrapa +:"taolf" == epytwen file +) +,hsadn=sehsad_mun +,lavwen=eulav +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPregetnI.ptxg = mrapa +:"regetni" == epytwen file +) +,hsadn=sehsad_mun +,lavwen=eulav +,plehwen=pleh +,lebalwen=lebal +,emanwen +(maraPtxeT.ptxg = mrapa +:"txet" == epytwen fi +)emanwen(hsadNteg.fles = hsadn +emanwen = lebalwen +:0 > )lebalwen(nel ton fi +"1" == ]"taeper"[p = sper +]"LCgiro"[p = lcdlo +]"LC"[p = lcwen +]"epyt"[p = epytwen +]"pleh"[p = plehwen +]"lebal"[p = lebalwen +]"eulav"[p = lavwen +]"eman"[p = emanwen +:rapdda.fles ni p rof +)mrapt(dneppa.maraptset.fles +)emanwen % "elpmas_s%"=eulav ,emanwen(maraPtseT.ptxg = mrapt +)tupnina(dneppa.stupnit.fles +:esle +)mrapt(dneppa.maraptset.fles +)2mrapt(dneppa.mrapt +)emanwen % "elpmas_s%"=eulav ,emanwen(maraPtseT.ptxg = 2mrapt +)"}emanwen{_R"f=eman(taepeRtseT.ptxg = mrapt +)eper(dneppa.stupnit.fles +)tupnina(dneppa.eper +) +"dedeen sa }bala{ ynam sa ddA"f=eltit ,"}emanwen{_R"f=eman +(taepeR.ptxg = eper +:sper fi +emanwen % "s%$" = edirrevo_enil_dnammoc.tupnina +)]"LCgiro"[p(tni = lanoitisop.tupnina +:esle +emanwen % "s%$ <" = edirrevo_enil_dnammoc.tupnina +8999999 = lanoitisop.tupnina +:"NIDTS" == )(reppu.]"LCgiro"[p fi +:lanoitisop_si.fles fi +lanoitisop_si.fles = lanoitisop.tupnina +) +,hsadn=sehsad_mun +,eslaF=elpitlum +,tmfwen=tamrof +,]"pleh"[p=pleh +,bala=lebal +,eslaF=lanoitpo +,emanwen +(maraPataD.ptxg = tupnina +]"lebal"[p = bala +:esle +]"LC"[p = bala +:0 > )]"lebal"[p(nel ton fi +"1" == )"0" ,"taeper"(teg.p = sper +)emanwen(hsadNteg.fles = hsadn +]"tamrof"[p = tmfwen +]"emanelifni"[p = emanwen +:selifni.fles ni p rof +)pt(dneppa.maraptset.fles +) +,c=erapmoc +,emanwen % "elpmas_s%"=eulav +,emanwen=eman +(tuptuOtseT.ptxg = pt +tset = c +:esle +) +,carf_atled=carf_atled +,atled=atled +,c=erapmoc +,emanwen % "elpmas_s%"=eulav +,emanwen=eman +(tuptuOtseT.ptxg = pt +enoN = carf_atled +)nt(tni = atled +:esle +))nt(taolf ,0.1(nim = carf_atled +enoN = atled +:nt ni "." fi +:"" > nt fi +)(pirts.]1[)":"(tilps.tset = nt +"ezis_mis" = c +:)"ezis_mis"(htiwstrats.tset file +) +,dl=ffid_senil +,c=erapmoc +,emanwen % "elpmas_s%"=eulav +,emanwen=eman +(tuptuOtseT.ptxg = pt +)]1[)":"(tilps.tset(tni = dl +:tigidsi.]1[)":"(tilps.tset fi +0 = dl +"ffid" = c +:)"ffid"(htiwstrats.)(pirts.tset fi +:"" > )(pirts.tset fi +enoN = dl +)mrapa(dneppa.stuptuot.fles +emanwen % "s%$" = edirrevo_enil_dnammoc.mrapa +)lcdlo(tni = lanoitisop.mrapa +:esle +emanwen % "s%$ >" = edirrevo_enil_dnammoc.mrapa +9999999 = lanoitisop.mrapa +:"TUODTS" == )(reppu.lcdlo fi +:lanoitisop_si.fles fi +lanoitisop_si.fles = lanoitisop.mrapa +) +emanwen=lebal ,hsadn=sehsad_mun ,tmfwen=tamrof ,emanwen=eman +(ataDtuptuO.ptxg = mrapa +)lcwen(hsadNteg.fles = hsadn +)(pirts.tset = tset +]"LCgiro"[p = lcdlo +]"tset"[p = tset +]"LC"[p = lcwen +]"tamrof"[p = tmfwen +]"eman"[p = emanwen +:seliftuo.fles ni p rof +"""loot ot stnemele dedeen lla ddA""" +aqon # :)fles(marapLMXod fed + +hsadn nruter +1 = hsadn +:2 < )emanwen(nel fi +2 = hsadn +:esle +0 = hsadn +:lanoitisop_si.fles fi +:)emanwen ,fles(hsadNteg fed + +)c(LCXa +:plc ni c rof +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)lc(LCXa +:tceriderlcxtsal.fles ni lc rof +:tceriderlcxtsal.fles fi +)v(LCXa +)k(LCXa +k % "s%--" = k +:esle +k % "s%-" = k +:1 == ))(pirts.k(nel fi +:esle +)k(LCXa +edirrevok = k +:"" > edirrevok fi +:xiffuslcx.fles ni )edirrevok ,v ,k( rof + +mrof deman esrapgra ni smarap neht stupni # +dneppa.lclmx.fles = LCXa +"""elyts esrapgra""" +:)fles(esrapgralc fed + +)c(LCXa +:plc ni c rof +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)lc(LCXa +:tceriderlcxtsal.fles ni lc rof +:tceriderlcxtsal.fles fi +)v(LCXa +:xiffuslcx.fles ni )edirrevok ,v ,k( rof +dneppa.lclmx.fles = LCXa +smarap neht redro ni stupni # +:)fles(lanoitisoplc fed + +pdda = ]i[rapdda.fles +]"LC"[pdda = ]"LCgiro"[pdda +)p(ypoc.ypoc = pdda +:)rapdda.fles(etaremune ni p ,i rof +pftuo = ]i[seliftuo.fles +ypoc peek # ]"LC"[pftuo = ]"LCgiro"[pftuo +)p(ypoc.ypoc = pftuo +:)seliftuo.fles(etaremune ni p ,i rof +pfni = ]i[selifni.fles +]"LC"[pfni = ]"emanelifni"[pfni +:esle +)"_" ," "(ecalper.]"lebal"[pfni = ]"emanelifni"[pfni +:]"0" ,"lanoitisop"[ ni ssapmarap.sgra.fles fi +]"LC"[pfni = ]"LCgiro"[pfni +)p(ypoc.ypoc = pfni +:)selifni.fles(etaremune ni p ,i rof +) +,]"eman"[p +,]"LC"[p +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,)(tigidsi.] +"LC" +[p tressa +:)rapdda.fles(etaremune ni p ,i rof +) +,]"eman"[p +,]"LC"[p +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,) +"TUODTS" == )(reppu.)(pirts.]"LC"[p ro )(tigidsi.]"LC"[p +( tressa +:)seliftuo.fles(etaremune ni p ,i rof +) +,]"lebal"[p +,]"LC"[p +( % "s% rof s% tog - sregetni lanidro eb tsum sretemarap lanoitisoP" ,) +"NIDTS" == )(reppu.)(pirts.]"LC"[p ro )(tigidsi.]"LC"[p +( tressa +:)selifni.fles(etaremune ni p ,i rof +:"lanoitisop" == ssapmarap.sgra.fles fi +"""lanidro ciremun rieht yb detacilpmoc era sretemarap lanoitisop """ +:)fles(rappunaelc fed + +)(esolc.tcafitra +))"8ftu" ,tpircs.fles(setyb(etirw.tcafitra +)"bw" ,tra(nepo = tcafitra +)]0[emetucexe.fles ,eman_loot.fles( % "s%.s%" = tra +xr = tpircSdepacse.fles +)"war dne#"(dneppa.xr +)"war#" ,0(tresni.xr +]"" > )(pirts.x fi xr ni x rof "}x{ "f[ = tpircSdecaps.fles +)(esolc.tpircst +)tpircs.fles(etirw.tpircst +)"w" ,elifs.fles(nepo = tpircst +) +)]0[emetucexe.fles( % "s%_"=xiffus ,eman_loot.fles=xiferp +(pmetskm.elifpmet = elifs.fles ,eldnahf +)xr(nioj."n\" = tpircs.fles +"nur tonnaC .ytpme si tpircs deilppuS" ,0 > )kcehcxr(nel tressa +]"" > )(pirts.x fi xr ni x rof )(pirts.x[ = kcehcxr +]xr ni x rof )(pirtsr.x[ = xr +)(senildaer.)"r" ,htap_tpircs.sgra.fles(nepo = xr +:)fles(tpircSperp fed + +xiffuslcx = xiffuslcx.fles +)(tros.xiffuslcx +)]]"edirrevo"[p ,]"eman"[p % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +:raples.fles ni p rof +)]revo ,man % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +]"edirrevo"[p = revo +) +"!senil dnammoc retemarap lanoitisop ni dettimrep ton - derongi }man{ rof staepeR .gninraw ###"f +(tnirp +:per fi +esnes ON ekam staeper # "1" == ]"taeper"[p = per +]"eman"[p = man +:rapdda.fles ni p rof +)]"" ,]"eman"[p % "s%$" ,]"LC"[p[(dneppa.xiffuslcx +:esle +]]"eman"[p % "s%$" ,">"[ = tceriderlcxtsal.fles +:"TUODTS" == )(reppu.)(pirts.]"LCgiro"[p fi +:)seliftuo.fles(etaremune ni p ,i rof +)emdneppax(dneppa.xiffuslcx +]"" ,]"emanelifni"[p % "s%$" ,]"LC"[p[ = emdneppax +:esle +] +,]"emanelifni"[p % "s%$ <" +,]"emanelifni"[p +,"999" +[ = emdneppax +:"NIDTS" == )(reppu.)(pirts.]"LCgiro"[p fi +:)selifni.fles(etaremune ni p ,i rof +][ = xiffuslcx +:)fles(soplcperp fed + +xiffuslcx = xiffuslcx.fles +)]]"edirrevo"[p ,]"eman"[p % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +:raples.fles ni p rof +)]revo ,man % '"s%$"' ,]"LC"[p[(dneppa.xiffuslcx +]"edirrevo"[p = revo +:esle +'rof dne#n\"}man{.per$" }man{--n\:}man{_R$ ni per$ rof#'f = revo +:per fi +"1" == ]"taeper"[p = per +]"eman"[p = man +:rapdda.fles ni p rof +)]"" ,]"eman"[p % "s%$" ,]"eman"[p[(dneppa.xiffuslcx +:esle +]]"eman"[p % "s%$" ,">"[ = tceriderlcxtsal.fles +:"TUODTS" == )(reppu.)(pirts.]"LCgiro"[p fi +:)seliftuo.fles(etaremune ni p ,i rof +)emdneppax(dneppa.xiffuslcx +]revo ,]"LC"[p % "s%$" ,]"LC"[p[ = emdneppax +'rof dne#n\"}man{.per$" }man{--n\:}man{_R$ ni per$ rof#'f = revo +:per fi +"" = revo +"1" == ]"taeper"[p = per +:esle +] +,man % "s%$ <" +,man +,man +[ = emdneppax +:"NIDTS" == )(reppu.)(pirts.]"LCgiro"[p fi +]"emanelifni"[p = man +:)selifni.fles(etaremune ni p ,i rof +][ = xiffuslcx +:)fles(pgraperp fed + +)c(LCXa +:plc ni c rof +)xiffus_resu_lc.sgra.fles(tilps.xelhs = plc +dne LC YID # :xiffus_resu_lc.sgra.fles fi +)]"eman"[]0[seliftuo.fles % "s%$"(LCXa +)">"(LCXa +:0 > )seliftuo.fles(nel fi +)]"emanelifni"[]0[selifni.fles % "s%$"(LCXa +)"<"(LCXa +:0 > )selifni.fles(nel fi +dneppa.lclmx.fles = LCXa +"""o/i rof > dna < sesu - staeper ro sretemarap on""" +:)fles(elpmislc fed + +)(esrapgralc.fles +)(pgraperp.fles +:esle +)(lanoitisoplc.fles +)(soplcperp.fles +:"lanoitisop" == ssapmarap.sgra.fles fi +:esle +)(elpmislc.fles +:"0" == ssapmarap.sgra.fles fi + +)xe(LCXa +:emetucexe.fles ni xe rof +:esle +)"emnur$"(LCXa +)xe(LCXa +:emetucexe.fles ni xe rof +:htap_tpircs.sgra.fles fi +enoN = edirrevo_tset.fles +:esle +]sots ni x rof )(pirtsr.x[ = edirrevo_tset.fles +)(senildaer.)"r" ,edirrevo_tset.sgra.fles(nepo = sots +:edirrevo_tset.sgra.fles fi +enoN = edirrevo_dnammoc.fles +:esle +]socs ni x rof )(pirtsr.x[ = edirrevo_dnammoc.fles +)(senildaer.)"r" ,edirrevo_dnammoc.sgra.fles(nepo = socs +:edirrevo_dnammoc.sgra.fles fi +)(tpircSperp.fles +:htap_tpircs.sgra.fles fi +][ = maraptset.fles +)(stuptuO.ptxg = stuptuot.fles +)(stupnI.ptxg = stupnit.fles +)eman_loot.fles % 'txt.gol_nur_FT_s%',ridper.fles(nioj.htap.so = golt.fles +)ridper.fles(ridkm.so +:)ridper.fles(stsixe.htap.so ton fi +)ridtset.fles(ridkm.so +:)ridtset.fles(stsixe.htap.so ton fi +)ridtuoloot.fles(ridkm.so +:)ridtuoloot.fles(stsixe.htap.so ton fi +)"atad-tset" ,ridtuoloot.fles(nioj.htap.so = ridtset.fles +)eman_loot.fles % "zg.dehsloot_detset_ton_s%" ,ridtuoloot.fles(nioj.htap.so # tuo_loot_detsetnu.sgra = htapratwen.fles +"negloot/." = ridper.fles +"tuoft/." = ridtuoloot.fles +) +,EXEEKAF +,csed_loot.sgra.fles +,noisrev_loot.sgra.fles +,di_loot.fles +,eman_loot.fles +(looT.txg = lootwen.fles +eman_loot.fles = di_loot.fles +)eman_loot.sgra ,"" ,"+]_9-0Z-Az-a^["(bus.er = eman_loot.fles +'"esrapgra" ro "lanoitisop","0" eb tsum ssapmarap.sgra' ,] +,"lanoitisop" +,"esrapgra" +,"0" +[ ni ssapmarap.sgra tressa +dneppa.lclmx.fles = LCXa +enoN = emetucexe.fles +:esle +] +,)(pirts.]0[)":"(tilps.]0[)","(tilps.segakcap.sgra.fles +[ = emetucexe.fles +:segakcap.sgra.fles fi +:esle +] +,exesys.sgra.fles +[ = emetucexe.fles +:esle +)exesys.sgra.fles(tilps.xelhs = emetucexe.fles +:exesys.sgra.fles ni " " fi +:exesys.sgra.fles fi +"lanoitisop" == ssapmarap.sgra.fles = lanoitisop_si.fles +][ = lclmx.fles +enoN = tceriderlcxtsal.fles +)(rappunaelc.fles +sgra = sgra.fles +) +"yranoitcid a eb dluohs - demroflam si }sretemarap_txettceles.sgra{ sretemarap_txettceles--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi sretemarap_txettceles.sgra ni x rof )x(sdaol.nosj +[ = raples.fles +:yrt +) +"yranoitcid a eb dluohs - demroflam si }sretemarap_lanoitidda.sgra{ sretemarap_lanoitidda--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi sretemarap_lanoitidda.sgra ni x rof )x(sdaol.nosj +[ = rapdda.fles +:yrt +'tros emos fo tuptuo na tuohtiw liaf lliw rennur boj yxalaG ehT .deificeps snoitcelloc tuptuo ro seliftuo oN' ,0 > ))snoitcelloc.fles(nel + )seliftuo.fles(nel( tressa +) +"yranoitcid a eb dluohs - demroflam si }selif_tuptuo.sgra{ retemarap selif_tuptuo--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi selif_tuptuo.sgra ni x rof )x(sdaol.nosj +[ = seliftuo.fles +:yrt +) +"yranoitcid a eb dluohs - demroflam si })selif_tupni.sgra(rts{ retemarap selif_tupni--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi selif_tupni.sgra ni x rof )x(sdaol.nosj +[ = selifni.fles +:yrt +) +"yranoitcid a eb dluohs - demroflam si })noitcelloc.sgra(rts{ retemarap snoitcelloc--"f +(tnirp +:noitpecxE tpecxe +] +1 > ))(pirts.x(nel fi noitcelloc.sgra ni x rof )x(sdaol.nosj +[ = snoitcelloc.fles +:yrt +:0 > )noitcelloc.sgra(nel fi +][ = snoitcelloc.fles +)(dwcteg.so = dwcruo.fles +)'sloot_lacol',toor_yxalag.sgra(nioj.htap.so = sloot_lacol.fles +""" +noitareneg loot lmxyxalag rof dedeen stnemele eraperp dna +ereh loot eht gninnur rof lc enil dnammoc eraperp +""" +aqon # :)enoN=sgra ,fles(__tini__ fed + +""" + +lmxyxalag sesu +tpircs yrartibra na rof repparW""" +:yrotcaF_looT ssalc + + +selput_noitatic nruter +)))(pirts.]: )"xetbib"(nel[noitatic ,"xetbib"((dneppa.selput_noitatic +:esle +)))(pirts.]: )"iod"(nel[noitatic ,"iod"((dneppa.selput_noitatic +:)"iod"(htiwstrats.noitatic fi +:snoitatic ni noitatic rof +][ = selput_noitatic +])(pirts.c fi )"**YRTNE**"(tilps.txet_snoitatic ni c rof c[ = snoitatic +"""""" +:)txet_snoitatic(snoitatic_esrap fed + + +)]txet ni c rof )c ,c(teg.elbat_epacse_hateehc[(nioj."" nruter +""".txet nihtiw seititne ecudorP""" +:)txet(epacse_hateehc fed + + +}"#\\" :"#" ,"$\\" :"$"{ = elbat_epacse_hateehc + + +)))(emit.emit(emitlacol.emit ,"S%:M%:H% Y%/m%/d%"(emitfrts.emit nruter +"""gnirts a sa emit tnerruc nruter""" +:)(wonemit fed + + +.edirrevo htiw # +neve exe eht gnidneperp lmxyxalag xif ot pmub noisrev/RP a litnu siht deen # +"~~~EM~~~EVOMER~~~" = EXEEKAF +"yrotcafloot/2rabuf/moc.buhtig//:sptth" = LRUyrotcaFloot +eurT = gubed +eurT = esobrev +"2202 hcraM 4.2V" = noisrevym + +lmay tropmi + +TE sa eerte.lmxl tropmi + +ptxg sa sretemarap.loot.lmxyxalag tropmi +txg sa loot.lmxyxalag tropmi + +yxalag tropmi dnelboib morf + +emit tropmi +elifpmet tropmi +elifrat tropmi +sys tropmi +ssecorpbus tropmi +lituhs tropmi +xelhs tropmi +er tropmi +so tropmi +nosj tropmi +ltncf tropmi +ypoc tropmi +esrapgra tropmi + + + +.tset htiw loot reporp wen a snruter dna # +stuptuo tset eht setaerc ,evihcra detset-non a no omenalp snur retset ehT # +noitpoda reniatnocoib dna tnempoleved lairotut NTG fo trap sa # +llatsni/tset dna etareneg - sloot owt otni derotcafeR :2202 hcram # +# +yrotcafloot/2rabuf/moc.buhtig//:sptth # +ta emoclew sexif gub dna tnemevorpmi rof snoitseggus # +LPGL eht rednu desneciL # +devreser sthgir lla # +# +2102 yaM )moc pots liamg ta surazal pots ssor( surazal ssor thgirypoc # +# +yrotcafloot/2rabuf/moc.buhtig//:sptth ees #
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tf_apikey_mutate/tf_apikey_mutate.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,186 @@ +<tool name="tf_apikey_mutate" id="tf_apikey_mutate" version="0.001"> + <!--Source in git at: https://github.com/fubar2/galaxy--> + <!--Created by toolfactory@galaxy.org at 21/05/2023 10:01:12 using the Galaxy Tool Factory.--> + <description>Rotates all API keys in a ToolFactory instance </description> + <requirements> + <requirement version="1.1.1" type="package">bioblend</requirement> + <requirement version="3.10.12" type="package">python</requirement> + <requirement type="package">six</requirement> + </requirements> + <stdio> + <exit_code range="1:" level="fatal"/> + </stdio> + <version_command><![CDATA[echo "0.001"]]></version_command> + <command><![CDATA[python +$runme --galaxy_root "$__root_dir__" --galaxy_venv "$__root_dir__/.venv" +> +$APIK_mutate_log]]></command> + <configfiles> + <configfile name="runme"><![CDATA[#raw + +#!/usr/bin/env python +import argparse +import hashlib +import os +import random +import subprocess +import sys +from time import sleep +from urllib import request +from urllib.error import URLError + +from bioblend import galaxy + +def add_user(sa_session, security_agent, email, password, key=None, username="admin"): + """ + Add Galaxy User. + From John https://gist.github.com/jmchilton/4475646 + """ + query = sa_session.query(User).filter_by(email=email) + user = None + uexists = False + User.use_pbkdf2 = False + if query.count() > 0: + user = query.first() + user.username = username + user.set_password_cleartext(password) + sa_session.add(user) + sa_session.flush() + uexists = True + else: + user = User(email) + user.username = username + user.set_password_cleartext(password) + sa_session.add(user) + sa_session.flush() + + security_agent.create_private_user_role(user) + if not user.default_permissions: + security_agent.user_set_default_permissions(user, history=True, dataset=True) + + if key is not None: + query = sa_session.query(APIKeys).filter_by(user_id=user.id).delete() + sa_session.flush() + + api_key = APIKeys() + api_key.user_id = user.id + api_key.key = key + sa_session.add(api_key) + sa_session.flush() + return user, uexists + +def run_sed(options): + """ + eg replacement = 'APIK="%s"' % options.key + line_start = 'APIK=' + """ + fixme = [] + tool_config_file: "tool_conf.xml,../local_tools/local_tool_conf.xml" + # database_connection: "sqlite:///<data_dir>/universe.sqlite?isolation_level=IMMEDIATE" + tfc = 'tool_conf.xml,%s/local_tools/local_tool_conf.xml' % options.galaxy_root + fixfile = "%s/config/galaxy.yml" % options.galaxy_root + fixme.append((' virtualenv: ', ' virtualenv: "%s"' % options.galaxy_venv, fixfile)) + fixme.append((' galaxy_root: ', ' galaxyroot: "%s"' % options.galaxy_root, fixfile)) + fixme.append((' tool_config_file: ', ' tool_config_file: "%s"' % tfc, fixfile)) + fixfile = "%s/local_tools/toolfactory/toolfactory.py" % options.galaxy_root + fixme.append((' self.GALAXY_ADMIN_KEY =', ' self.GALAXY_ADMIN_KEY = "%s"' % options.key, fixfile )) + fixme.append((' self.GALAXY_URL = ' , ' self.GALAXY_URL = "%s"' % options.galaxy_url, fixfile )) + fixfile = "%s/local_tools/toolfactory/install_tf_deps.sh" % options.galaxy_root + fixme.append(('APIK=', 'APIK="%s"' % options.key, fixfile )) + fixme.append(('LOCALTOOLDIR=', 'LOCALTOOLDIR="%s"' % os.path.join(os.path.abspath(options.galaxy_root), "local_tools"), fixfile )) + fixfile = "%s/local_tools/toolfactory/localplanemotest.sh" % options.galaxy_root + fixme.append(('GALAXY_URL=', 'GALAXY_URL=%s' % options.galaxy_url, fixfile)) + fixme.append(('API_KEY=', 'API_KEY=%s' % options.key, fixfile)) + fixfile = "%s/local_tools/toolfactory/toolfactory_fast_test.sh" % options.galaxy_root + fixme.append(('GALAXY_URL=', 'GALAXY_URL=%s' % options.galaxy_url, fixfile)) + fixme.append(('API_KEY=', 'API_KEY=%s' % options.key, fixfile)) + fixme.append(('GALAXY_VENV=', 'GALAXY_VENV=%s' % options.galaxy_venv, fixfile)) + fixme.append(('API_KEY_USER=', 'API_KEY_USER=%s' % options.botkey, fixfile)) + for line_start, line_replacement, file_to_edit in fixme: + cmd = ["sed", "-i", "s#.*%s.*#%s#g" % (line_start, line_replacement), file_to_edit] + print("## executing", ' '.join(cmd)) + res = subprocess.run(cmd) + if not res.returncode == 0: + print('### Non zero %d return code from %s ' % (res.returncode, ''.join(cmd))) + + +if __name__ == "__main__": + print('starting!', file=sys.stderr) + apikey = "%s" % hash(random.random()) + apikey2 = "%s" % hash(random.random()) + parser = argparse.ArgumentParser(description="Create Galaxy Admin User.") + parser.add_argument("--galaxy_url", help="Galaxy server URL", default="http://localhost:8080") + parser.add_argument("--galaxy_root", help="Galaxy root directory path", default="/work/galaxytf") + parser.add_argument("--galaxy_venv", help="Galaxy venv path", default="/work/galaxytf/.venv") + parser.add_argument("--user", help="Username - an email address.", default="toolfactory@galaxy.org") + parser.add_argument("--password", help="Password", default="ChangeMe!") + parser.add_argument("--password2", help="Password", default=apikey2) + parser.add_argument("--key", help="API-Key.", default=apikey) + parser.add_argument("--botkey", help="bot API-Key.", default=apikey2) + parser.add_argument("--username", default="tfadmin") + parser.add_argument("args", nargs=argparse.REMAINDER) + options = parser.parse_args() + sys.path.insert(1, options.galaxy_root) + sys.path.insert(1, os.path.join(options.galaxy_root, "lib")) + sys.path.insert(1, os.path.join(options.galaxy_venv, "lib", "python3.10", "site-packages")) + from galaxy.model import User, APIKeys + from galaxy.model.mapping import init + from galaxy.model.orm.scripts import get_config + cnf = get_config(argv=['-c','galaxy', ],cwd=options.galaxy_root) + print('cnf=%s' % cnf, file=sys.stderr) + cdb_url = cnf["db_url"] + # or perhaps "postgresql:///ubuntu?host=/var/run/postgresql" + # this is harder to please get_config(sys.argv, use_argparse=False)["db_url"] + print('### Using cdb_url', cdb_url, file=sys.stderr) + mapping = init("/tmp/", cdb_url) + sa_session = mapping.context + security_agent = mapping.security_agent + usr, uexists = add_user( + sa_session, security_agent, options.user, options.password, key=options.key, username=options.username + ) + print("added user", options.user, "apikey", options.key, file=sys.stderr) + + usr, uexists = add_user( + sa_session, security_agent, 'test@bx.psu.edu', options.password2, key=options.botkey, username='bot' + ) + run_sed(options) + print('Evil deeds done', file=sys.stderr) + + +#end raw]]></configfile> + </configfiles> + <inputs/> + <outputs> + <data name="APIK_mutate_log" format="txt" label="APIK_mutate_log" hidden="false"/> + </outputs> + <tests> + <test> + <output name="APIK_mutate_log" value="APIK_mutate_log_sample" compare="sim_size" delta="100"/> + </test> + </tests> + <help><![CDATA[ + +**What it Does** + +Regenerates fresh API keys for the ToolFactory administrative user and rewrites them into all the relevant utility code. + +The Docker image is constructed with a new set of keys but they are identical in every image, so running this tool +in that image makes sure that while it is running, it is not using the distributed keys. It will do the same thing for a +local disk installation but has already been run once at first boot. No real harm running it again to recycle all your keys +if you like. + +Will break the ToolFactory if it breaks. +Safe in Docker since it's not persistent :) +Use at your own peril. +This is a crazy tool to run. + +This script consistently fails tool test, but actually works fine on a ToolFactory docker or local installation. +It reuses code from the initial configuration to create new, random API keys for the admin logins. + + +]]></help> + <citations> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/install_tf_deps.sh Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,17 @@ +LOCALTOOLDIR="/home/ross/rossgit/galaxytf231/local_tools" +APIK="1718977735397126400" +GAL="http://localhost:8080" +# all unless a single id is passed in as $1 +if [ -z "$1" ]; then + for f in $LOCALTOOLDIR/*; do + if [ -d "$f" ]; then + TOOL=`basename "$f"` + install_tool_deps -v -g $GAL -a $APIK -t $LOCALTOOLDIR/$TOOL/$TOOL.xml + fi + done +else + install_tool_deps -v -g $GAL -a $APIK -t $LOCALTOOLDIR/$1/$1.xml +fi + + +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/localplanemotest.sh Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,6 @@ +# pass path to tool as parameter /work/galaxytf/local_tools/tacrev/tacrev.xml +GALAXY_URL=http://localhost:8080 +API_KEY=1718977735397126400 +# for test@bx.psu.edu user +# for sed to edit at installation +planemo test --galaxy_admin_key $API_KEY --engine external_galaxy --galaxy_url $GALAXY_URL --update_test_data $1
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/test-data/input1_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,741 @@ +#!/usr/bin/env python +# rgToolFactory.py +# see https://github.com/fubar2/toolfactory +# +# copyright ross lazarus (ross stop lazarus at gmail stop com) May 2012 +# +# all rights reserved +# Licensed under the LGPL +# suggestions for improvement and bug fixes welcome at https://github.com/fubar2/toolfactory +# +# July 2020: BCC was fun and I feel like rip van winkle after 5 years. +# Decided to +# 1. Fix the toolfactory so it works - done for simplest case +# 2. Fix planemo so the toolfactory function works +# 3. Rewrite bits using galaxyxml functions where that makes sense - done +# +# removed all the old complications including making the new tool use this same script +# galaxyxml now generates the tool xml https://github.com/hexylena/galaxyxml +# No support for automatic HTML file creation from arbitrary outputs +# TODO: add option to run that code as a post execution hook +# TODO: add additional history input parameters - currently only one + + +import argparse +import logging +import os +import re +import shutil +import subprocess +import sys +import tarfile +import tempfile +import time + +import galaxyxml.tool as gxt +import galaxyxml.tool.parameters as gxtp + +import lxml + +myversion = "V2.1 July 2020" +verbose = True +debug = True +toolFactoryURL = "https://github.com/fubar2/toolfactory" +ourdelim = "~~~" + +# --input_files="$input_files~~~$CL~~~$input_formats~~~$input_label +# ~~~$input_help" +IPATHPOS = 0 +ICLPOS = 1 +IFMTPOS = 2 +ILABPOS = 3 +IHELPOS = 4 +IOCLPOS = 5 + +# --output_files "$otab.history_name~~~$otab.history_format~~~$otab.CL +ONAMEPOS = 0 +OFMTPOS = 1 +OCLPOS = 2 +OOCLPOS = 3 + +# --additional_parameters="$i.param_name~~~$i.param_value~~~ +# $i.param_label~~~$i.param_help~~~$i.param_type~~~$i.CL~~~i$.param_CLoverride" +ANAMEPOS = 0 +AVALPOS = 1 +ALABPOS = 2 +AHELPPOS = 3 +ATYPEPOS = 4 +ACLPOS = 5 +AOVERPOS = 6 +AOCLPOS = 7 + + +foo = len(lxml.__version__) +# fug you, flake8. Say my name! + +def timenow(): + """return current time as a string + """ + return time.strftime("%d/%m/%Y %H:%M:%S", time.localtime(time.time())) + + +def quote_non_numeric(s): + """return a prequoted string for non-numerics + useful for perl and Rscript parameter passing? + """ + try: + _ = float(s) + return s + except ValueError: + return '"%s"' % s + + +html_escape_table = {"&": "&", ">": ">", "<": "<", "$": r"\$"} + + +def html_escape(text): + """Produce entities within text.""" + return "".join(html_escape_table.get(c, c) for c in text) + + +def html_unescape(text): + """Revert entities within text. Multiple character targets so use replace""" + t = text.replace("&", "&") + t = t.replace(">", ">") + t = t.replace("<", "<") + t = t.replace("\\$", "$") + return t + + +def parse_citations(citations_text): + """ + """ + citations = [c for c in citations_text.split("**ENTRY**") if c.strip()] + citation_tuples = [] + for citation in citations: + if citation.startswith("doi"): + citation_tuples.append(("doi", citation[len("doi") :].strip())) + else: + citation_tuples.append( + ("bibtex", citation[len("bibtex") :].strip()) + ) + return citation_tuples + + +class ScriptRunner: + """Wrapper for an arbitrary script + uses galaxyxml + + """ + + def __init__(self, args=None): + """ + prepare command line cl for running the tool here + and prepare elements needed for galaxyxml tool generation + """ + + self.infiles = [x.split(ourdelim) for x in args.input_files] + self.outfiles = [x.split(ourdelim) for x in args.output_files] + self.addpar = [x.split(ourdelim) for x in args.additional_parameters] + self.args = args + self.cleanuppar() + self.lastclredirect = None + self.lastxclredirect = None + self.cl = [] + self.xmlcl = [] + self.is_positional = self.args.parampass == "positional" + aCL = self.cl.append + assert args.parampass in [ + "0", + "argparse", + "positional", + ], 'Parameter passing in args.parampass must be "0","positional" or "argparse"' + self.tool_name = re.sub("[^a-zA-Z0-9_]+", "", args.tool_name) + self.tool_id = self.tool_name + if self.args.interpreter_name: + exe = "$runMe" + else: + exe = self.args.exe_package + assert ( + exe is not None + ), "No interpeter or executable passed in - nothing to run so cannot build" + self.tool = gxt.Tool( + self.args.tool_name, + self.tool_id, + self.args.tool_version, + self.args.tool_desc, + exe, + ) + self.tinputs = gxtp.Inputs() + self.toutputs = gxtp.Outputs() + self.testparam = [] + if ( + self.args.runmode == "Executable" or self.args.runmode == "system" + ): # binary - no need + aCL(self.args.exe_package) # this little CL will just run + else: + self.prepScript() + self.elog = "%s_error_log.txt" % self.tool_name + self.tlog = "%s_runner_log.txt" % self.tool_name + + if self.args.parampass == "0": + self.clsimple() + else: + clsuffix = [] + xclsuffix = [] + for i, p in enumerate(self.infiles): + if p[IOCLPOS] == "STDIN": + appendme = [ + p[IOCLPOS], + p[ICLPOS], + p[IPATHPOS], + "< %s" % p[IPATHPOS], + ] + xappendme = [ + p[IOCLPOS], + p[ICLPOS], + p[IPATHPOS], + "< $%s" % p[ICLPOS], + ] + else: + appendme = [p[IOCLPOS], p[ICLPOS], p[IPATHPOS], ""] + xappendme = [p[IOCLPOS], p[ICLPOS], "$%s" % p[ICLPOS], ""] + clsuffix.append(appendme) + xclsuffix.append(xappendme) + # print('##infile i=%d, appendme=%s' % (i,appendme)) + for i, p in enumerate(self.outfiles): + if p[OOCLPOS] == "STDOUT": + self.lastclredirect = [">", p[ONAMEPOS]] + self.lastxclredirect = [">", "$%s" % p[OCLPOS]] + else: + clsuffix.append([p[OOCLPOS], p[OCLPOS], p[ONAMEPOS], ""]) + xclsuffix.append( + [p[OOCLPOS], p[OCLPOS], "$%s" % p[ONAMEPOS], ""] + ) + for p in self.addpar: + clsuffix.append( + [p[AOCLPOS], p[ACLPOS], p[AVALPOS], p[AOVERPOS]] + ) + xclsuffix.append( + [p[AOCLPOS], p[ACLPOS], '"$%s"' % p[ANAMEPOS], p[AOVERPOS]] + ) + clsuffix.sort() + xclsuffix.sort() + self.xclsuffix = xclsuffix + self.clsuffix = clsuffix + if self.args.parampass == "positional": + self.clpositional() + else: + self.clargparse() + + def prepScript(self): + aCL = self.cl.append + rx = open(self.args.script_path, "r").readlines() + rx = [x.rstrip() for x in rx] + rxcheck = [x.strip() for x in rx if x.strip() > ""] + assert len(rxcheck) > 0, "Supplied script is empty. Cannot run" + self.script = "\n".join(rx) + fhandle, self.sfile = tempfile.mkstemp( + prefix=self.tool_name, suffix="_%s" % (self.args.interpreter_name) + ) + tscript = open(self.sfile, "w") + tscript.write(self.script) + tscript.close() + self.indentedScript = " %s" % "\n".join( + [" %s" % html_escape(x) for x in rx] + ) + self.escapedScript = "%s" % "\n".join( + [" %s" % html_escape(x) for x in rx] + ) + art = "%s.%s" % (self.tool_name, self.args.interpreter_name) + artifact = open(art, "wb") + artifact.write(bytes(self.script, "utf8")) + artifact.close() + aCL(self.args.interpreter_name) + aCL(self.sfile) + + def cleanuppar(self): + """ positional parameters are complicated by their numeric ordinal""" + for i, p in enumerate(self.infiles): + if self.args.parampass == "positional": + assert p[ICLPOS].isdigit(), ( + "Positional parameters must be ordinal integers - got %s for %s" + % (p[ICLPOS], p[ILABPOS]) + ) + p.append(p[ICLPOS]) + if p[ICLPOS].isdigit() or self.args.parampass == "0": + scl = "input%d" % (i + 1) + p[ICLPOS] = scl + self.infiles[i] = p + for i, p in enumerate( + self.outfiles + ): # trying to automagically gather using extensions + if self.args.parampass == "positional" and p[OCLPOS] != "STDOUT": + assert p[OCLPOS].isdigit(), ( + "Positional parameters must be ordinal integers - got %s for %s" + % (p[OCLPOS], p[ONAMEPOS]) + ) + p.append(p[OCLPOS]) + if p[OCLPOS].isdigit() or p[OCLPOS] == "STDOUT": + scl = p[ONAMEPOS] + p[OCLPOS] = scl + self.outfiles[i] = p + for i, p in enumerate(self.addpar): + if self.args.parampass == "positional": + assert p[ACLPOS].isdigit(), ( + "Positional parameters must be ordinal integers - got %s for %s" + % (p[ACLPOS], p[ANAMEPOS]) + ) + p.append(p[ACLPOS]) + if p[ACLPOS].isdigit(): + scl = "input%s" % p[ACLPOS] + p[ACLPOS] = scl + self.addpar[i] = p + + def clsimple(self): + """ no parameters - uses < and > for i/o + """ + aCL = self.cl.append + aCL("<") + aCL(self.infiles[0][IPATHPOS]) + aCL(">") + aCL(self.outfiles[0][OCLPOS]) + aXCL = self.xmlcl.append + aXCL("<") + aXCL("$%s" % self.infiles[0][ICLPOS]) + aXCL(">") + aXCL("$%s" % self.outfiles[0][ONAMEPOS]) + + def clpositional(self): + # inputs in order then params + aCL = self.cl.append + for (o_v, k, v, koverride) in self.clsuffix: + if " " in v: + aCL("%s" % v) + else: + aCL(v) + aXCL = self.xmlcl.append + for (o_v, k, v, koverride) in self.xclsuffix: + aXCL(v) + if self.lastxclredirect: + aXCL(self.lastxclredirect[0]) + aXCL(self.lastxclredirect[1]) + + def clargparse(self): + """ argparse style + """ + aCL = self.cl.append + aXCL = self.xmlcl.append + # inputs then params in argparse named form + for (o_v, k, v, koverride) in self.xclsuffix: + if koverride > "": + k = koverride + elif len(k.strip()) == 1: + k = "-%s" % k + else: + k = "--%s" % k + aXCL(k) + aXCL(v) + for (o_v, k, v, koverride) in self.clsuffix: + if koverride > "": + k = koverride + elif len(k.strip()) == 1: + k = "-%s" % k + else: + k = "--%s" % k + aCL(k) + aCL(v) + + def getNdash(self, newname): + if self.is_positional: + ndash = 0 + else: + ndash = 2 + if len(newname) < 2: + ndash = 1 + return ndash + + def doXMLparam(self): + """flake8 made me do this...""" + for p in self.outfiles: + newname, newfmt, newcl, oldcl = p + ndash = self.getNdash(newcl) + aparm = gxtp.OutputData(newcl, format=newfmt, num_dashes=ndash) + aparm.positional = self.is_positional + if self.is_positional: + if oldcl == "STDOUT": + aparm.positional = 9999999 + aparm.command_line_override = "> $%s" % newcl + else: + aparm.positional = int(oldcl) + aparm.command_line_override = "$%s" % newcl + self.toutputs.append(aparm) + tp = gxtp.TestOutput( + name=newcl, value="%s_sample" % newcl, format=newfmt + ) + self.testparam.append(tp) + for p in self.infiles: + newname = p[ICLPOS] + newfmt = p[IFMTPOS] + ndash = self.getNdash(newname) + if not len(p[ILABPOS]) > 0: + alab = p[ICLPOS] + else: + alab = p[ILABPOS] + aninput = gxtp.DataParam( + newname, + optional=False, + label=alab, + help=p[IHELPOS], + format=newfmt, + multiple=False, + num_dashes=ndash, + ) + aninput.positional = self.is_positional + self.tinputs.append(aninput) + tparm = gxtp.TestParam(name=newname, value="%s_sample" % newname) + self.testparam.append(tparm) + for p in self.addpar: + newname, newval, newlabel, newhelp, newtype, newcl, override, oldcl = p + if not len(newlabel) > 0: + newlabel = newname + ndash = self.getNdash(newname) + if newtype == "text": + aparm = gxtp.TextParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "integer": + aparm = gxtp.IntegerParam( + newname, + label=newname, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "float": + aparm = gxtp.FloatParam( + newname, + label=newname, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + else: + raise ValueError( + 'Unrecognised parameter type "%s" for\ + additional parameter %s in makeXML' + % (newtype, newname) + ) + aparm.positional = self.is_positional + if self.is_positional: + aninput.positional = int(oldcl) + self.tinputs.append(aparm) + self.tparm = gxtp.TestParam(newname, value=newval) + self.testparam.append(tparm) + + def doNoXMLparam(self): + alab = self.infiles[0][ILABPOS] + if len(alab) == 0: + alab = self.infiles[0][ICLPOS] + max1s = ( + "Maximum one input if parampass is 0 - more than one input files supplied - %s" + % str(self.infiles) + ) + assert len(self.infiles) == 1, max1s + newname = self.infiles[0][ICLPOS] + aninput = gxtp.DataParam( + newname, + optional=False, + label=alab, + help=self.infiles[0][IHELPOS], + format=self.infiles[0][IFMTPOS], + multiple=False, + num_dashes=0, + ) + aninput.command_line_override = "< $%s" % newname + aninput.positional = self.is_positional + self.tinputs.append(aninput) + tp = gxtp.TestParam(name=newname, value="%s_sample" % newname) + self.testparam.append(tp) + newname = self.outfiles[0][OCLPOS] + newfmt = self.outfiles[0][OFMTPOS] + anout = gxtp.OutputData(newname, format=newfmt, num_dashes=0) + anout.command_line_override = "> $%s" % newname + anout.positional = self.is_positional + self.toutputs.append(anout) + tp = gxtp.TestOutput( + name=newname, value="%s_sample" % newname, format=newfmt + ) + self.testparam.append(tp) + + def makeXML(self): + """ + Create a Galaxy xml tool wrapper for the new script + Uses galaxyhtml + Hmmm. How to get the command line into correct order... + """ + self.tool.command_line_override = self.xmlcl + if self.args.interpreter_name: + self.tool.interpreter = self.args.interpreter_name + if self.args.help_text: + helptext = open(self.args.help_text, "r").readlines() + helptext = [html_escape(x) for x in helptext] + self.tool.help = "".join([x for x in helptext]) + else: + self.tool.help = ( + "Please ask the tool author (%s) for help \ + as none was supplied at tool generation\n" + % (self.args.user_email) + ) + self.tool.version_command = None # do not want + requirements = gxtp.Requirements() + + if self.args.interpreter_name: + if self.args.interpreter_name == "python": + requirements.append( + gxtp.Requirement( + "package", "python", self.args.interpreter_version + ) + ) + elif self.args.interpreter_name not in ["bash", "sh"]: + requirements.append( + gxtp.Requirement( + "package", + self.args.interpreter_name, + self.args.interpreter_version, + ) + ) + else: + if self.args.exe_package and self.args.parampass != "system": + requirements.append( + gxtp.Requirement( + "package", + self.args.exe_package, + self.args.exe_package_version, + ) + ) + self.tool.requirements = requirements + if self.args.parampass == "0": + self.doNoXMLparam() + else: + self.doXMLparam() + self.tool.outputs = self.toutputs + self.tool.inputs = self.tinputs + if self.args.runmode not in ["Executable", "system"]: + configfiles = gxtp.Configfiles() + configfiles.append(gxtp.Configfile(name="runMe", text=self.script)) + self.tool.configfiles = configfiles + tests = gxtp.Tests() + test_a = gxtp.Test() + for tp in self.testparam: + test_a.append(tp) + tests.append(test_a) + self.tool.tests = tests + self.tool.add_comment( + "Created by %s at %s using the Galaxy Tool Factory." + % (self.args.user_email, timenow()) + ) + self.tool.add_comment("Source in git at: %s" % (toolFactoryURL)) + self.tool.add_comment( + "Cite: Creating re-usable tools from scripts doi: 10.1093/bioinformatics/bts573" + ) + exml = self.tool.export() + xf = open('%s.xml' % self.tool_name, "w") + xf.write(exml) + xf.write("\n") + xf.close() + # ready for the tarball + + def makeTooltar(self): + """ + a tool is a gz tarball with eg + /toolname/tool.xml /toolname/tool.py /toolname/test-data/test1_in.foo ... + NOTE names for test inputs and outputs are munged here so must + correspond to actual input and output names used on the generated cl + """ + retval = self.run() + if retval: + sys.stderr.write( + "## Run failed. Cannot build yet. Please fix and retry" + ) + sys.exit(1) + tdir = "tfout" + if not os.path.exists(tdir): + os.mkdir(tdir) + self.makeXML() + testdir = os.path.join(tdir, "test-data") + if not os.path.exists(testdir): + os.mkdir(testdir) # make tests directory + for p in self.infiles: + pth = p[IPATHPOS] + dest = os.path.join(testdir, "%s_sample" % p[ICLPOS]) + shutil.copyfile(pth, dest) + for p in self.outfiles: + pth = p[OCLPOS] + if p[OOCLPOS] == "STDOUT" or self.args.parampass == "0": + pth = p[ONAMEPOS] + dest = os.path.join(testdir, "%s_sample" % p[ONAMEPOS]) + shutil.copyfile(pth, dest) + dest = os.path.join(tdir, p[ONAMEPOS]) + shutil.copyfile(pth, dest) + else: + pth = p[OCLPOS] + dest = os.path.join(testdir, "%s_sample" % p[OCLPOS]) + shutil.copyfile(pth, dest) + dest = os.path.join(tdir, p[OCLPOS]) + shutil.copyfile(pth, dest) + + if os.path.exists(self.tlog) and os.stat(self.tlog).st_size > 0: + shutil.copyfile(self.tlog, os.path.join(testdir, "test1_log_outfiletxt")) + if self.args.runmode not in ["Executable", "system"]: + stname = os.path.join(tdir, "%s" % (self.sfile)) + if not os.path.exists(stname): + shutil.copyfile(self.sfile, stname) + xreal = '%s.xml' % self.tool_name + xout = os.path.join(tdir,xreal) + shutil.copyfile(xreal, xout) + tarpath = "toolfactory_%s.tgz" % self.tool_name + tf = tarfile.open(tarpath, "w:gz") + tf.add(name=tdir, arcname=self.tool_name) + tf.close() + shutil.copyfile(tarpath, self.args.new_tool) + shutil.copyfile(xreal,"tool_xml.txt") + repdir = "TF_run_report_tempdir" + if not os.path.exists(repdir): + os.mkdir(repdir) + repoutnames = [x[OCLPOS] for x in self.outfiles] + with os.scandir('.') as outs: + for entry in outs: + if entry.name.endswith('.tgz') or not entry.is_file(): + continue + if entry.name in repoutnames: + shutil.copyfile(entry.name,os.path.join(repdir,entry.name)) + elif entry.name == "%s.xml" % self.tool_name: + shutil.copyfile(entry.name,os.path.join(repdir,"new_tool_xml")) + return retval + + def run(self): + """ + Some devteam tools have this defensive stderr read so I'm keeping with the faith + Feel free to update. + """ + s = "run cl=%s" % str(self.cl) + + logging.debug(s) + scl = " ".join(self.cl) + err = None + if self.args.parampass != "0": + ste = open(self.elog, "wb") + if self.lastclredirect: + sto = open( + self.lastclredirect[1], "wb" + ) # is name of an output file + else: + sto = open(self.tlog, "wb") + sto.write( + bytes( + "## Executing Toolfactory generated command line = %s\n" + % scl, + "utf8", + ) + ) + sto.flush() + p = subprocess.run(self.cl, shell=False, stdout=sto, stderr=ste) + sto.close() + ste.close() + tmp_stderr = open(self.elog, "rb") + err = "" + buffsize = 1048576 + try: + while True: + err += str(tmp_stderr.read(buffsize)) + if not err or len(err) % buffsize != 0: + break + except OverflowError: + pass + tmp_stderr.close() + retval = p.returncode + else: # work around special case of simple scripts that take stdin and write to stdout + sti = open(self.infiles[0][IPATHPOS], "rb") + sto = open(self.outfiles[0][ONAMEPOS], "wb") + # must use shell to redirect + p = subprocess.run(self.cl, shell=False, stdout=sto, stdin=sti) + retval = p.returncode + sto.close() + sti.close() + if os.path.isfile(self.tlog) and os.stat(self.tlog).st_size == 0: + os.unlink(self.tlog) + if os.path.isfile(self.elog) and os.stat(self.elog).st_size == 0: + os.unlink(self.elog) + if p.returncode != 0 and err: # problem + sys.stderr.write(err) + logging.debug("run done") + return retval + + +def main(): + """ + This is a Galaxy wrapper. It expects to be called by a special purpose tool.xml as: + <command interpreter="python">rgBaseScriptWrapper.py --script_path "$scriptPath" --tool_name "foo" --interpreter "Rscript" + </command> + """ + parser = argparse.ArgumentParser() + a = parser.add_argument + a("--script_path", default="") + a("--tool_name", default=None) + a("--interpreter_name", default=None) + a("--interpreter_version", default=None) + a("--exe_package", default=None) + a("--exe_package_version", default=None) + a("--input_files", default=[], action="append") + a("--output_files", default=[], action="append") + a("--user_email", default="Unknown") + a("--bad_user", default=None) + a("--make_Tool", default=None) + a("--help_text", default=None) + a("--tool_desc", default=None) + a("--tool_version", default=None) + a("--citations", default=None) + a("--additional_parameters", action="append", default=[]) + a("--edit_additional_parameters", action="store_true", default=False) + a("--parampass", default="positional") + a("--tfout", default="./tfout") + a("--new_tool", default="new_tool") + a("--runmode", default=None) + args = parser.parse_args() + assert not args.bad_user, ( + 'UNAUTHORISED: %s is NOT authorized to use this tool until Galaxy admin adds %s to "admin_users" in the Galaxy configuration file' + % (args.bad_user, args.bad_user) + ) + assert ( + args.tool_name + ), "## Tool Factory expects a tool name - eg --tool_name=DESeq" + assert ( + args.interpreter_name or args.exe_package + ), "## Tool Factory wrapper expects an interpreter or an executable package" + assert args.exe_package or ( + len(args.script_path) > 0 and os.path.isfile(args.script_path) + ), "## Tool Factory wrapper expects a script path - eg --script_path=foo.R if no executable" + args.input_files = [ + x.replace('"', "").replace("'", "") for x in args.input_files + ] + # remove quotes we need to deal with spaces in CL params + for i, x in enumerate(args.additional_parameters): + args.additional_parameters[i] = args.additional_parameters[i].replace( + '"', "" + ) + r = ScriptRunner(args) + if args.make_Tool: + retcode = r.makeTooltar() + else: + retcode = r.run() + if retcode: + sys.exit(retcode) # indicate failure to job runner + + +if __name__ == "__main__": + main()
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/test-data/output2_sample Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,165 @@ +*trats uoy erofeb GNINRAW* + +YLNO yxalaG etavirp a no loot siht llatsnI +ecnatsni noitcudorp ro cilbup a no REVEN esaelP + +troppus noitatic gnidda notlihC nhoJ yb 4102 tsugua detadpU + +keeB ned nav suiraM yb detroper sgub xif ot 4102 8 tsugua detadpU + +ta ecruoser eht etic esaelP +fer=epytyek&JWYdwMrWs1hQzcl=yekji?375stb/tnirper/igc/gro.slanruojdrofxo.scitamrofnioib//:ptth +.krow dehsilbup ruoy ni loot siht esu uoy fi + +**yrotS trohS** + +.sloot yxalaG wen gnitareneg fo elbapac loot yxalaG lausunu na si sihT +gnitpircs suoregnad ylemertxe erofereht dna *detcirtsernu* gnisopxe yb skrow tI +ot meht gniwolla ,revres yxalaG tsoh eht fo srotartsinimda detangised lla ot +,stes atad tupni detceles elpitlum revo lrep dna hs ,nohtyp ,R ni stpircs nur +.tuptuo sa tes atad wen elgnis a gnitirw + +*sretemarap elyts esrapgra ro lanoitisop htiw elbatucexe yna ro tpircs hsab/lrep/nohtyp/r gnikrow a evah uoY* + +.loot yxalaG a gnisu ,setunim ni loot yxalaG yranidro na otni denrut eb nac tI + + +**yxalaG yna otni noitallatsni rof sloot yxalaG wen fo noitareneg detamotuA** + +.ylppus uoy sgnittes retemarap dna stupni atad tset elpmas llams gnisu detareneg si tset A +a dliub ot desu eb nac yeht ,decudorp neeb evah stuptuo esac tset eht ecnO +tnemeriuqer a sa dekab si elbatucexe ro tpircs deilppus ehT .loot yxalaG wen +.xob eht fo tuo elbitapmoc wolfkrow ylluf ,loot yxalaG yranidro ,wen a otni +rotartsinimda na yb dehs loot a aiv dellatsni era sloot detareneG +.sresu ruoy rof sloot yxalaG rehto lla ekil yltcaxe krow dna + +**liateD eroM** + +a otni etsap ot tpircs a deraperp evah dluohs uoy ,yrotcaFlooT eht esu oT +yrotsih ruoy morf tceles ot ydaer elpmaxe tupni tset llams a dna dnim ni egakcap a evah ro ,xob txet +.tpircs wen ruoy tset ot + +em rof skrow ```atad-tset/yrotcafloot/srekam_loot/sloot/yxalag/~ atad_tset-- yxalag/~ toor_yxalag-- lmx.2yrotcaFlooTgr tset omenalp``` + +uoY .mrof yrotcaF looT eht no egaugnal gnitpircs hcae ni elpmaxe na si erehT +thgir eht tceles ot rebmemer - tuo ti yrt ot eseht etsap dna tuc tsuj nac +gnisu tes atad tset llams a etaerc ot deen osla ll'uoY .esaelp reterpretni +.loot atad wen dda yrotsih yxalaG eht + +ni tuptuo loot eht no nottub "oder" eht esu ,wohemos sliaf tpircs eht fI +gub eht xiF .tpircs nekorb htiw etelpmoc mrof eht etaercer ot yrotsih ruoy +.taeper ,hsaw ,esniR .niaga etucexe dna + +tpircs ruoy snur taht loot yxalaG wen a ,yllufssecus snur tpircs eht ecnO +dna txet pleh emos ylppus dna noitpo "etareneg" eht tceleS .detareneg eb nac +epytatad yxalaG wen a fo mrof eht ni detareneg eb lliw loot wen ehT .seman +a ot daolpu ot ydaer evihcra na s'ti ,stseggus eman eht sa - *zg.dehsloot* +.yrotisoper loot wen a sa dehSlooT yxalaG + +revres yxalaG lacol yna otni dellatsni eb nac ti ,dehSlooT a ni s'ti ecnO +.ecafretni evitartsinimda revres eht morf + +tpircs eht ,emit hcae - ti nur nac sresu lacol ,dellatsni si loot wen eht ecnO +nesohc tupni eht htiw detucexe eb lliw tliub saw ti nehw deilppus saw taht +eht htiw etareneg uoy sloot eht ,sdrow rehto nI .yrotsih s'resu eht morf +.emit yreve tpircs ruoy nur tub,loot yxalaG rehto yna ekil tsuj nur yrotcaFlooT + +,tuptuo eno ,tupni enO .stnenopmoc wolfkrow rof tcefrep era sloot yrotcaf looT +.selbairav on + +,loot siht fo *rewop emosewa eht tiolpxe ylefas dna ylluf oT* +siht gnillatsni repoleved a eb dluohs uoy ,dehSlooT eht dna yxalaG +na era uoy erehw ecnatsni lacol hctarcs/lanosrep/etavirp a no loot +ees seceip eht lla peek ot teg uoy ,ti kaerb uoy fi ,nehT .resu_nimda +emoH/ikiw/yrotcaflootyxalag/rabuf/gro.tekcubtib//:sptth + +**noitallatsnI** +eht gnisu yltneinevnoc tsom ti llatsni nac uoY .loot yxalaG a si sihT +niaM yxalaG eht dniF .knil "sdehs loot esworb dna hcraeS" evitartsinimda +yrotcafloot eht rof hcraes dna /ude.usp.xb.2g.dehsloot//:sptth ta dehsloot +.ti llatsni ot noitpo eht tceles dna edoc eht weiver dna ti nepO .yrotisoper + +eb ot deen ereh selif yp dna lmx eht ,yaw taht loot eht teg t'nac uoy fI +sloot wen a otni deipoc +yrtne wen a sdeen lmx.fnoc_loot ruoY yrotcafloot/sloot sa hcus yrotceridbus +lmx eht ot gnitniop +::ekil gnihtemos - elif + +>"sredliubloot"=di "sloot gnidliub looT"=eman noitces< +>/"lmx.yrotcaFlooTgr/yrotcafloot"=elif loot< +>noitces/< + +,ereht ydaerla ton fI +:dda esaelp +"yraniB:yranib.sepytatad.yxalag"=epyt "zg.dehsloot"=noisnetxe epytatad< +>/ "eurT"=ssalcbus "pizg-x/trapitlum"=epytemim +.lmx.fnoc_sepyt_atad lacol ruoy ot + + +**noitucexe detcirtseR** + +- sresu nimda yb YLNO elbasu eb neht lliw flesti loot yrotcaf loot ehT +YLNO .thgir s'taht ,seY** ini.igsw_esrevinu ni sresu_nimda ni sDI htiw elpoep +ot dewolla fI .tnemom a rof ti tuoba knihT **loot siht nur nac sresu_nimda +dluow taht gniht ylno eht ,revres yxalaG ruoy no tpircs yrartibra yna nur +ylbaborp dluow atad yxalaG ruoy lla gniyortsed no tneb tnaercsim a edepmi +.slliks lacinhcet etairporppa fo kcal eb + +**seod ti tahW** + +dna R ,nohtyp ni stpircs elpmis rof yrotcaf loot a si sihT +.taht si looc woH .detareneg yllacitamotua era stset lanoitcnuF .yltnerruc lrep + +nac yllanoitpO .yrotsih eht morf tupni eno daer taht stpircs elpmis ot DETIMIL +stuptuo fo rebmun yna tcelloc yllanoitpo dna ,tesatad yrotsih wen eno etirw +- etagivan ot resu eht rof egap xedni LMTH detarenegotua na no sknil otni +nwohs era stuptuo fdp - selif tuptuo dna segami setirw tpircs eht fi lufesu +dna taht os tpircstsohg htiw knurhs era s'fdp detaolb s'R dna slianbmuht sa +.elbaliava eb ot deen kigamegami + +trats os ,loot yxalaG yna ekil decnahne dna detide eb nac sloot detareneG +a ot pu gel suoires a uoy steg tpircs detareneg a ecnis pu dliub dna llams +.eno xelpmoc erom + +**od uoy tahW** + +dna srorre xatnys eht xif uoy ,tpircs ruoy nur dna etsap uoY +erofeb tpircs eht tide dna nottub oder eht esu nac uoY .snur ti yllautneve +.llew ytterp skrow ti - gubed uoy sa ti nurer ot gniyrt + +elbitapmoc dehsloot a etareneg nac uoy ,atad tset emos no skrow tpircs eht ecnO +ni loot yxalaG yranidro na sa nur ot ydaer tpircs ruoy gniniatnoc elif pizg +detamotua ylegral dna efas snaem tahT .dehsloot lacol ruoy no yrotisoper a +.dehsloot ruoy esu ot derugifnoc yxalaG noitcudorp yna ni noitallatsni + +**ytiruceS loot detareneG** + +tsuj s'ti ,loot detareneg a llatsni uoy ecnO +rieht dna yllamron nur tsuj yehT .efas si tpircs eht gnimussa - loot rehtona +.dehsloot efas ecitcarp ,esaelp tub erucesni yllausunu gnihtyna od tonnac resu +.yracs yllaer si ti - eno siht yllaicepsE .loot yna llatsni uoy erofeb edoc eht daeR + +**edoC dneS** + +?esaelp seussi tekcubtib sa emoclew snoitseggus dna sehctaP + +**noitubirttA** + +yrotcaF looT yxalaG ehT :stpircs morf sloot elbasu-er gnitaerC +maeT yxalaG ehT ;nnameiZ kraM ;ipsaK ynotnA ;surazaL ssoR +375stb/scitamrofnioib/3901.01 :iod ;2102 scitamrofnioiB + +fer=epytyek&JWYdwMrWs1hQzcl=yekji?375stb/tnirper/igc/gro.slanruojdrofxo.scitamrofnioib//:ptth + +**gnisneciL** + +0102 surazaL ssoR thgirypoC +moc doirep liam g ta surazal ssor + +.devreser sthgir llA + +LPGL eht rednu desneciL + +**tohsneercs yrotagilbO** + +gnp.looTtpircScimanyd/segami/989ef2308adf/crs/rekamlootyxalag/rabuf/gro.tekcubtib//:ptth
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/test-data/pyrevpos.python Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,13 @@ +# reverse order of text by row +import sys +inp = sys.argv[1] +outp = sys.argv[2] +i = open(inp,'r').readlines() +o = open(outp,'w') +for row in i: + rs = row.rstrip() + rs = list(rs) + rs.reverse() + o.write(''.join(rs)) +o.close() +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/test-data/test1_log.txt Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1 @@ +## Executing Toolfactory generated command line = python /tmp/pyrevposq5dmcdy1.python /tmp/tmpqrksf8sd/files/5/b/9/dataset_5b952a86-87df-44ad-a415-ea549f3f0cee.dat output2
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/toolfactory.py Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,1393 @@ +# see https://github.com/fubar2/toolfactory +# +# copyright ross lazarus (ross stop lazarus at gmail stop com) May 2012 +# +# all rights reserved +# Licensed under the LGPL +# suggestions for improvement and bug fixes welcome at +# https://github.com/fubar2/toolfactory +# +# February 2023: Refactored to use galaxy-tool-test script in galaxyutil +# planemo not needed if tool is already installed. +# sqlite does not seem to work - switch to postgresql in the installation script +# +# march 2022: Refactored into two tools - generate and test/install +# as part of GTN tutorial development and biocontainer adoption +# The tester runs planemo on a non-tested archive, creates the test outputs +# and returns a new proper tool with test. + + +import argparse +import copy +import json +import logging +import os +import re +import shlex +import shutil +import subprocess +import sys +import tarfile +import tempfile +import time + +from bioblend import galaxy +from bioblend import ConnectionError + +import galaxyxml.tool as gxt +import galaxyxml.tool.parameters as gxtp + +import lxml.etree as ET + +import yaml + + +logger = logging.getLogger(__name__) + + +class Tool_Factory: + """Wrapper for an arbitrary script + uses galaxyxml + """ + + def __init__(self, args=None): # noqa + """ + prepare command line cl for running the tool here + and prepare elements needed for galaxyxml tool generation + """ + assert args.parampass in [ + "0", + "embed", + "argparse", + "positional", + "embednfmod", + ], ( + "args.parampass %s not 0,positional, embed, embednfmod or argparse" + % args.parampass + ) + # sed will update these settings during tfsetup.py first run + self.GALAXY_ADMIN_KEY = "1718977735397126400" + self.GALAXY_URL = "http://localhost:8080" + self.profile = "22.05" + self.not_iuc = True + self.args = args + self.tool_version = self.args.tool_version + self.myversion = "V3.0 February 2023" + self.verbose = True + self.debug = True + self.toolFactoryURL = "https://github.com/fubar2/galaxy_tf_overlay" + self.logger = logging.getLogger(__name__) + self.nfcoremod = False + if args.parampass == "embednfmod": + self.nfcoremod = True + self.script_in_help = False # IUC recommendation + self.tool_name = re.sub("[^a-zA-Z0-9_]+", "", args.tool_name) + self.tool_id = self.tool_name + self.local_tools = os.path.realpath( + os.path.join(args.galaxy_root, "local_tools") + ) + self.repdir = os.path.realpath(args.tfcollection) + self.testdir = os.path.join(self.repdir, self.tool_name) + self.toold = os.path.join(self.local_tools, self.tool_name) + self.tooltestd = os.path.join(self.toold, "test-data") + if self.nfcoremod: + self.local_tools = os.path.join(args.tfcollection, "tools") + self.repdir = os.path.join(args.tfcollection, "TFouts", self.tool_name) + self.toold = os.path.join(self.local_tools, self.tool_name) + self.tooltestd = os.path.join(self.toold, "test-data") + os.makedirs(self.repdir, exist_ok=True) + os.makedirs(self.toold, exist_ok=True) + os.makedirs(self.tooltestd, exist_ok=True) + os.makedirs(self.local_tools, exist_ok=True) + self.local_tool_conf = os.path.join(self.local_tools, "local_tool_conf.xml") + self.ourcwd = os.getcwd() + self.collections = [] + if len(args.collection) > 0: + try: + self.collections = [ + json.loads(x) for x in args.collection if len(x.strip()) > 1 + ] + except Exception: + self.logger.error( + f"--collections parameter {str(args.collection)} is malformed - should be a dictionary" + ) + self.infiles = [] + try: + self.infiles = [ + json.loads(x) for x in args.input_files if len(x.strip()) > 1 + ] + except Exception: + self.logger.error( + f"--input_files parameter {str(args.input_files)} is malformed - should be a dictionary" + ) + self.extra_files = [] + if len(args.xtra_files) > 0: + try: + self.extra_files = [ + json.loads(x) for x in args.xtra_files if len(x.strip()) > 1 + ] + except Exception: + self.logger.error( + f"--xtra_files parameter {str(args.xtra_files)} is malformed - should be a dictionary" + ) + self.outfiles = [] + try: + self.outfiles = [ + json.loads(x) for x in args.output_files if len(x.strip()) > 1 + ] + except Exception: + self.logger.error( + f"--output_files parameter {args.output_files} is malformed - should be a dictionary" + ) + assert ( + len(self.outfiles) + len(self.collections) + ) > 0, "No outfiles or output collections specified. The Galaxy job runner will fail without an output of some sort" + self.addpar = [] + try: + self.addpar = [ + json.loads(x) for x in args.additional_parameters if len(x.strip()) > 1 + ] + except Exception: + self.logger.error( + f"--additional_parameters {args.additional_parameters} is malformed - should be a dictionary" + ) + self.selpar = [] + try: + self.selpar = [ + json.loads(x) for x in args.selecttext_parameters if len(x.strip()) > 1 + ] + except Exception: + self.logger.error( + f"--selecttext_parameters {args.selecttext_parameters} is malformed - should be a dictionary" + ) + self.selfagpar = [] + try: + self.selflagpar = [ + json.loads(x) for x in args.selectflag_parameters if len(x.strip()) > 1 + ] + except Exception: + self.logger.error( + f"--selectflag_parameters {args.selecttext_parameters} is malformed - should be a dictionary" + ) + self.cleanuppar() + self.lastxclredirect = None + self.xmlcl = [] + self.is_positional = self.args.parampass == "positional" + self.is_embedded = self.args.parampass == "embedded" + if self.args.sysexe: + if " " in self.args.sysexe: + self.executeme = shlex.split(self.args.sysexe) + else: + self.executeme = [ + self.args.sysexe, + ] + else: + if self.args.packages: + self.executeme = [ + self.args.packages.split(",")[0].split(":")[0].strip(), + ] + else: + self.executeme = [] + aXCL = self.xmlcl.append + self.newtarpath = args.tested_tool_out + self.tinputs = gxtp.Inputs() + self.toutputs = gxtp.Outputs() + self.testparam = [] + if self.args.script_path: + self.prepScript() + else: + self.script = None + if self.args.cl_override != None: + scos = open(self.args.cl_override, "r").readlines() + self.cl_override = [x.rstrip() for x in scos] + else: + self.cl_override = None + if self.args.test_override != None: + stos = open(self.args.test_override, "r").readlines() + self.test_override = [x.rstrip() for x in stos] + else: + self.test_override = None + if self.args.cl_prefix != None: + scos = open(self.args.cl_prefix, "r").readlines() + self.cl_prefix = [x.rstrip() for x in scos] + else: + self.cl_prefix = None + if self.args.cl_suffix != None: + stos = open(self.args.cl_suffix, "r").readlines() + self.cl_suffix = [x.rstrip() for x in stos] + else: + self.cl_suffix = None + if self.args.script_path: + for ex in self.executeme: + if ex: + aXCL(ex) + aXCL("'$runme'") + else: + for ex in self.executeme: + aXCL(ex) + if self.args.parampass == "0": + self.clsimple() + elif self.args.parampass == "positional": + self.prepclpos() + self.clpositional() + elif self.args.parampass == "argparse": + self.prepargp() + self.clargparse() + elif self.args.parampass.startswith("embed"): + self.prepembed() + else: + logging.error( + "Parampass value %s not in 0, positional, argparse, embed or embednfmod" + % self.args.parampass + ) + logging.shutdown() + sys.exit(6) + + def clsimple(self): + """no parameters or repeats - uses < and > for i/o""" + aXCL = self.xmlcl.append + if len(self.infiles) > 0: + aXCL("<") + aXCL("'$%s'" % self.infiles[0]["infilename"]) + if len(self.outfiles) > 0: + aXCL(">") + aXCL("'$%s'" % self.outfiles[0]["name"]) + + def prepembed(self): + """fix self.script""" + scrip = self.script + if self.nfcoremod: + self.script = ( + '#set prefix = "%s"\n#set task_process = "%s"\n' + % (self.tool_name, self.tool_name) + + scrip + ) + self.xmlcl = [] # wipe anything there + aX = self.xmlcl.append + aX("") + if self.nfcoremod: + aX('#set prefix = "%s"' % self.tool_name) + aX('#set task_process = "%s"' % self.tool_name) + for p in self.collections: + aX("mkdir -p %s &&" % p["name"]) + aX("%s '$runme'" % self.args.sysexe) + + def prepargp(self): + xclsuffix = [] + for i, p in enumerate(self.infiles): + rep = p["required"] in ["optional1", "required1"] + req = p["required"] in ["required", "required1"] + nam = p["infilename"] + flag = p["CL"] + if p["origCL"].strip().upper() == "STDIN": + xappendme = [ + nam, + nam, + "< '$%s'" % nam, + ] + else: + xappendme = [p["CL"], "'$%s'" % p["CL"], ""] + xclsuffix.append(xappendme) + for i, p in enumerate(self.outfiles): + if p["origCL"].strip().upper() == "STDOUT": + self.lastxclredirect = [">", "'$%s'" % p["name"]] + else: + xclsuffix.append([p["name"], "'$%s'" % p["name"], ""]) + for p in self.addpar: + nam = p["name"] + val = p["value"] + flag = p["CL"] + rep = p.get("repeat", 0) == "1" + if rep: + over = f'#for $rep in $R_{nam}:\n--{nam} "$rep.{nam}"\n#end for' + else: + over = p.get("override", "") + if p["type"] == "clflag": + over = f'#if ${nam} == "set"\n --{flag}\n#end if' + xclsuffix.append([p["CL"], "'$%s'" % nam, over]) + for p in self.selpar: + xclsuffix.append([p["CL"], "'$%s'" % p["name"], p.get("override", "")]) + for p in self.selflagpar: + xclsuffix.append(["", "'$%s'" % p["name"], ""]) + for p in self.collections: + newname = p["name"] + xclsuffix.append([newname, "'%s'" % newname, ""]) + self.xclsuffix = xclsuffix + + def prepclpos(self): + xclsuffix = [] + for i, p in enumerate(self.infiles): + if p["origCL"].strip().upper() == "STDIN": + xappendme = [ + "999", + p["infilename"], + "< '$%s'" % p["infilename"], + ] + else: + xappendme = [p["CL"], "'$%s'" % p["infilename"], ""] + xclsuffix.append(xappendme) + for i, p in enumerate(self.outfiles): + if p["origCL"].strip().upper() == "STDOUT": + self.lastxclredirect = [">", "'$%s'" % p["name"]] + else: + xclsuffix.append([p["CL"], "'$%s'" % p["name"], ""]) + for p in self.addpar: + nam = p["name"] + rep = p.get("repeat", "0") == "1" # repeats make NO sense + if rep: + logger.warning( + f"### warning. Repeats for {nam} ignored - not permitted in positional parameter command lines!" + ) + over = p.get("override", "") + xclsuffix.append([p["CL"], "'$%s'" % nam, over]) + for p in self.selpar: + xclsuffix.append([p["CL"], "'$%s'" % p["name"], p.get("override", "")]) + for p in self.selflagpar: + xclsuffix.append(["", "'$%s'" % p["name"], ""]) + for p in self.collections: + newname = p["name"] + xclsuffix.append([newname, "'$%s'" % newname, ""]) + xclsuffix.sort() + self.xclsuffix = xclsuffix + + def prepScript(self): + s = open(self.args.script_path, "r").read() + ss = s.split("\n") + rxcheck = [x for x in ss if x.strip() > ""] + assert len(rxcheck) > 0, "Supplied script is empty. Cannot run" + if self.args.sysexe and self.args.parampass != "embed": + rxcheck.insert(0, "#raw") + rxcheck.append("#end raw") + self.script = "\n".join(rxcheck) + if len(self.executeme) > 0: + self.sfile = os.path.join( + self.repdir, "%s.%s.txt" % (self.tool_name, self.executeme[0]) + ) + else: + self.sfile = os.path.join( + self.repdir, "%s.script.txt" % (self.tool_name) + ) + tscript = open(self.sfile, "w") + tscript.write(self.script) + tscript.write("\n") + tscript.close() + self.spacedScript = [ + f" {x.replace('${','$ {')}" for x in ss if x.strip() > "" + ] + self.escapedScript = rxcheck + + def cleanuppar(self): + """positional parameters are complicated by their numeric ordinal""" + if self.args.parampass == "positional": + for i, p in enumerate(self.infiles): + assert ( + p["CL"].isdigit() or p["CL"].strip().upper() == "STDIN" + ), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["label"], + ) + for i, p in enumerate(self.outfiles): + assert ( + p["CL"].isdigit() or p["CL"].strip().upper() == "STDOUT" + ), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["name"], + ) + for i, p in enumerate(self.addpar): + assert p[ + "CL" + ].isdigit(), "Positional parameters must be ordinal integers - got %s for %s" % ( + p["CL"], + p["name"], + ) + for i, p in enumerate(self.infiles): + infp = copy.copy(p) + infp["origCL"] = infp["CL"] + if self.args.parampass in ["positional", "0"]: + infp["infilename"] = infp["label"].replace(" ", "_") + else: + infp["infilename"] = infp["CL"] + self.infiles[i] = infp + for i, p in enumerate(self.outfiles): + outfp = copy.copy(p) + outfp["origCL"] = outfp["CL"] # keep copy + if outfp.get("label", None) == None: + outfp["label"] = "" + self.outfiles[i] = outfp + for i, p in enumerate(self.addpar): + addp = copy.copy(p) + addp["origCL"] = addp["CL"] + self.addpar[i] = addp + for i, p in enumerate(self.collections): + addp = copy.copy(p) + addp["CL"] = addp["name"] + self.collections[i] = addp + + def clpositional(self): + # inputs in order then params + aXCL = self.xmlcl.append + for (k, v, koverride) in self.xclsuffix: + aXCL(v) + if self.lastxclredirect: + for cl in self.lastxclredirect: + aXCL(cl) + + def clargparse(self): + """argparse style""" + aXCL = self.xmlcl.append + # inputs then params in argparse named form + for (k, v, koverride) in self.xclsuffix: + if koverride > "": + k = koverride + aXCL(k) + else: + kl = len(k.strip()) + if kl == 0: + k = " " + elif kl == 1: + k = "-%s" % k + else: + k = "--%s" % k + aXCL(k) + aXCL(v) + if self.lastxclredirect: + for cl in self.lastxclredirect: + aXCL(cl) + + def getNdash(self, newname): + if self.is_positional: + ndash = 0 + else: + ndash = 2 + if len(newname) < 2: + ndash = 1 + return ndash + + def doXMLparam(self): # noqa + """Add all needed elements to tool""" + for p in self.outfiles: + newname = p["name"] + newfmt = p["format"] + newcl = p["CL"] + test = p["test"] + oldcl = p["origCL"] + test = test.strip() + filta = p.get("when", []) + lab = p.get("label", "") + if len(lab.strip()) == 0: + lab = newname + ndash = self.getNdash(newcl) + aparm = gxtp.OutputData( + name=newname, format=newfmt, num_dashes=ndash, label=lab + ) + if len(filta) > 0: + ofilta = gxtp.ChangeFormat() + for ( + whens + ) in filta: # when input=|image_type| value=|large_png| format=|png| + whenss = whens.replace("|", '"').replace("when ", "") + clauses = whenss.split() + for c in clauses: + if c.startswith("value"): + v = c.split("=")[1] + elif c.startswith("format"): + f = c.split("=")[1] + elif c.startswith("input"): + i = c.split("=")[1] + else: + print( + "bad when - need value=, format= and input=, got", whens + ) + owhen = gxtp.ChangeFormatWhen(format=f, input=i, value=v) + ofilta.append(owhen) + aparm.append(ofilta) + aparm.positional = self.is_positional + if self.is_positional: + if oldcl.upper() == "STDOUT": + aparm.positional = 9999999 + aparm.command_line_override = "> '$%s'" % newname + else: + aparm.positional = int(oldcl) + aparm.command_line_override = "'$%s'" % newname + self.toutputs.append(aparm) + ld = None + if test.strip() > "": + if test.strip().startswith("diff"): + c = "diff" + ld = 0 + if test.split(":")[1].isdigit: + ld = int(test.split(":")[1]) + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + lines_diff=ld, + ) + elif test.startswith("sim_size"): + c = "sim_size" + tn = test.split(":")[1].strip() + if tn > "": + if "." in tn: + delta = None + delta_frac = min(1.0, float(tn)) + else: + delta = int(tn) + delta_frac = None + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + delta=delta, + delta_frac=delta_frac, + ) + else: + c = test + tp = gxtp.TestOutput( + name=newname, + value="%s_sample" % newname, + compare=c, + ) + self.testparam.append(tp) + for p in self.infiles: + newname = p["infilename"] + newfmt = p["format"] + ndash = self.getNdash(newname) + reps = p.get("required", "") in ["optional1", "required1"] + isoptional = p.get("required", "") in ["optional", "optional1"] + if not len(p["label"]) > 0: + alab = p["CL"] + else: + alab = p["label"] + aninput = gxtp.DataParam( + newname, + optional=isoptional, + label=alab, + help=p["help"], + format=newfmt, + multiple=reps, + num_dashes=ndash, + ) + aninput.positional = self.is_positional + if self.is_positional: + if p["origCL"].upper() == "STDIN": + aninput.positional = 9999998 + aninput.command_line_override = "< '$%s'" % newname + else: + aninput.positional = int(p["origCL"]) + aninput.command_line_override = "'$%s'" % newname + self.tinputs.append(aninput) + tparm = gxtp.TestParam(newname, value="%s_sample" % newname) + self.testparam.append(tparm) + for p in self.addpar: + newname = p["name"] + newval = p.get("value", "") + newlabel = p["label"] + newhelp = p.get("help", "") + newtype = p.get("type", "?") + newcl = p["CL"] + oldcl = p["origCL"] + reps = p.get("repeat", "0") == "1" + if not len(newlabel) > 0: + newlabel = newname + ndash = self.getNdash(newname) + if newtype == "text": + aparm = gxtp.TextParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "integer": + aparm = gxtp.IntegerParam( + newname, + label=newlabel, + help=newhelp, + value=int(newval.replace("'", "").replace('"', "")), + num_dashes=ndash, + ) + elif newtype == "float": + aparm = gxtp.FloatParam( + newname, + label=newlabel, + help=newhelp, + value=float(newval.replace("'", "").replace('"', "")), + num_dashes=ndash, + ) + elif newtype == "boolean": + aparm = gxtp.BooleanParam( + newname, + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + elif newtype == "clflag": + initval = newval + aparm = gxtp.SelectParam( + newname, + label=newlabel, + help=newhelp, + num_dashes=ndash, + display="radio", + ) + anoptt = gxtp.SelectOption( + value="set", + text="Set this flag", + ) + anoptf = gxtp.SelectOption( + value="notset", + text="Do not set this flag", + ) + if p["value"] == "set": # make default same as form + aparm.append(anoptt) + aparm.append(anoptf) + else: + aparm.append(anoptf) + aparm.append(anoptt) + elif newtype == "datacolumn": + aparm = gxtp.TextParam( + newname, + type="data_column", + data_ref=p["dataref"], + multiple=(p["multiple"] == "1"), + label=newlabel, + help=newhelp, + value=newval, + num_dashes=ndash, + ) + else: + raise ValueError( + 'Unrecognised parameter type "%s" for \ + additional parameter %s in makeXML' + % (newtype, newname) + ) + aparm.positional = self.is_positional + if self.is_positional: + aparm.positional = int(oldcl) + if reps: + repe = gxtp.Repeat( + name=f"R_{newname}", + title=f"Any number of {newlabel} repeats are allowed", + ) + repe.append(aparm) + self.tinputs.append(repe) + tparm = gxtp.TestRepeat(name=f"R_{newname}") + tparm2 = gxtp.TestParam(newname, value=newval) + tparm.append(tparm2) + self.testparam.append(tparm) + else: + self.tinputs.append(aparm) + tparm = gxtp.TestParam(newname, value=newval) + self.testparam.append(tparm) + for p in self.selpar: + newname = p["name"] + newval = p.get("value", "") + newlabel = p["label"] + newhelp = p["help"] + newtype = p["type"] + newcl = p["CL"] + if not len(newlabel) > 0: + newlabel = newname + ndash = self.getNdash(newname) + if newtype == "selecttext": + newtext = p["texts"] + aparm = gxtp.SelectParam( + newname, + label=newlabel, + help=newhelp, + num_dashes=ndash, + ) + for i in range(len(newval)): + anopt = gxtp.SelectOption( + value=newval[i], + text=newtext[i], + ) + aparm.append(anopt) + aparm.positional = self.is_positional + if self.is_positional: + aparm.positional = int(newcl) + self.tinputs.append(aparm) + tparm = gxtp.TestParam(newname, value=newval[0]) + self.testparam.append(tparm) + else: + raise ValueError( + 'Unrecognised parameter type "%s" for\ + selecttext parameter %s in makeXML' + % (newtype, newname) + ) + for p in self.selflagpar: + newname = p["name"] + newval = p["value"] + newlabel = p["label"] + newhelp = p["help"] + newtype = p["type"] + newtext = p["texts"] + newcl = p["CL"] + if not len(newlabel) > 0: + newlabel = newname + aparm = gxtp.SelectParam( + newname, + label=newlabel, + help=newhelp, + num_dashes=0, + ) + for i in range(len(newval)): + anopt = gxtp.SelectOption( + value=newval[i], + text=newtext[i], + ) + aparm.append(anopt) + aparm.positional = self.is_positional + if self.is_positional: + aparm.positional = int(newcl) + self.tinputs.append(aparm) + tparm = gxtp.TestParam(newname, value=newval[0]) + self.testparam.append(tparm) + + def doNoXMLparam(self): + """filter style package - stdin to stdout""" + if len(self.infiles) > 0: + alab = self.infiles[0]["label"] + if len(alab) == 0: + alab = self.infiles[0]["infilename"] + max1s = ( + "Maximum one input if parampass is 0 but multiple input files supplied - %s" + % str(self.infiles) + ) + assert len(self.infiles) == 1, max1s + newname = self.infiles[0]["infilename"] + aninput = gxtp.DataParam( + newname, + optional=False, + label=alab, + help=self.infiles[0]["help"], + format=self.infiles[0]["format"], + multiple=False, + num_dashes=0, + ) + aninput.command_line_override = "< $%s" % newname + aninput.positional = True + self.tinputs.append(aninput) + tp = gxtp.TestParam(name=newname, value="%s_sample" % newname) + self.testparam.append(tp) + if len(self.outfiles) > 0: + newname = self.outfiles[0]["name"] + newfmt = self.outfiles[0]["format"] + anout = gxtp.OutputData(newname, format=newfmt, num_dashes=0) + anout.command_line_override = "> $%s" % newname + anout.positional = self.is_positional + self.toutputs.append(anout) + tp = gxtp.TestOutput(name=newname, value="%s_sample" % newname) + self.testparam.append(tp) + + def makeXML(self): # noqa + """ + Create a Galaxy xml tool wrapper for the new script + Uses galaxyhtml + Hmmm. How to get the command line into correct order... + """ + requirements = gxtp.Requirements() + self.condaenv = [] + if self.args.packages: + try: + for d in self.args.packages.split(","): + ver = None + packg = None + d = d.replace("==", ":") + d = d.replace("=", ":") + if ":" in d: + packg, ver = d.split(":")[:2] + ver = ver.strip() + packg = packg.strip() + self.tool_version = ver + else: + packg = d.strip() + ver = None + if ver == "": + ver = None + if packg: + requirements.append( + gxtp.Requirement("package", packg.strip(), ver) + ) + self.condaenv.append(d) + except Exception: + self.logger.error( + "### malformed packages string supplied - cannot parse = %s" + % self.args.packages + ) + sys.exit(2) + elif self.args.container: + requirements.append(gxtp.Requirement("container", self.args.container)) + self.newtool = gxt.Tool( + self.tool_name, + self.tool_id, + self.tool_version, + self.args.tool_desc, + "", + profile=self.profile, + ) + self.newtool.requirements = requirements + iXCL = self.xmlcl.insert + aXCL = self.xmlcl.append + if self.args.cl_prefix: # DIY CL start + self.xmlcl = self.cl_prefix + self.xmlcl + if self.args.cl_suffix: # DIY CL end + self.xmlcl += self.cl_suffix + if self.cl_override: + self.newtool.command_override = self.cl_override # config file + else: + self.newtool.command_override = self.xmlcl + self.cites = self.parse_citations() + cite = gxtp.Citations() + if self.cites and len(self.cites) > 0: + for c in self.cites: + acite = gxtp.Citation(type=c[0], value=c[1]) + cite.append(acite) + acite = gxtp.Citation(type="doi", value="10.1093/bioinformatics/bts573") + cite.append(acite) + self.newtool.citations = cite + safertext = "" + if self.args.help_text: + self.helptext = open(self.args.help_text, "r").readlines() + safertext = "\n".join([self.cheetah_escape(x) for x in self.helptext]) + if len(safertext.strip()) == 0: + safertext = ( + "Ask the tool author (%s) to rebuild with help text please\n" + % (self.args.user_email) + ) + if self.script_in_help and self.args.script_path: + if len(safertext) > 0: + safertext = safertext + "\n\n------\n" # transition allowed! + scr = [x for x in self.spacedScript if x.strip() > ""] + scr.insert(0, "\n\nScript::\n") + if len(scr) > 300: + scr = ( + scr[:100] + + [" >300 lines - stuff deleted", " ......"] + + scr[-100:] + ) + scr.append("\n") + safertext = safertext + "\n".join(scr) + self.newtool.help = " ".join(self.helptext) + for p in self.collections: + newkind = p["kind"] + newname = p["name"] + newlabel = p["label"] + newdisc = p["discover"] + collect = gxtp.OutputCollection(newname, label=newlabel, type=newkind) + disc = gxtp.DiscoverDatasets( + pattern=newdisc, directory=f"{newname}", visible="false" + ) + collect.append(disc) + self.toutputs.append(collect) + try: + tparm = gxtp.TestOutputCollection(newname) # broken until PR merged. + self.testparam.append(tparm) + except Exception: + logging.error( + "WARNING: Galaxyxml version does not have the PR merged yet - tests for collections must be over-ridden until then!" + ) + self.newtool.version_command = f'echo "{self.tool_version}"' + if self.args.parampass == "0": + self.doNoXMLparam() + else: + self.doXMLparam() + self.newtool.outputs = self.toutputs + self.newtool.inputs = self.tinputs + if self.args.script_path: + configfiles = gxtp.Configfiles() + configfiles.append(gxtp.Configfile(name="runme", text=self.script)) + self.newtool.configfiles = configfiles + tests = gxtp.Tests() + test_a = gxtp.Test() + for tp in self.testparam: + test_a.append(tp) + tests.append(test_a) + self.newtool.tests = tests + self.newtool.add_comment( + "Created by %s at %s using the Galaxy Tool Factory." + % (self.args.user_email, self.timenow()) + ) + self.newtool.add_comment("Source in git at: %s" % (self.toolFactoryURL)) + exml = self.newtool.export() + if ( + self.test_override + ): # cannot do this inside galaxyxml as it expects lxml objects for tests + part1 = exml.split("<tests>")[0] + part2 = exml.split("</tests>")[1] + fixed = "%s\n%s\n%s" % (part1, "\n".join(self.test_override), part2) + exml = fixed + with open(os.path.join(self.toold, "%s.xml" % self.tool_name), "w") as xf: + xf.write(exml) + xf.write("\n") + with open(os.path.join(self.repdir, "%s_xml.xml" % self.tool_name), "w") as xf: + xf.write(exml) + xf.write("\n") + + def writeShedyml(self): + """for planemo""" + yuser = self.args.user_email.split("@")[0] + yfname = os.path.join(self.toold, ".shed.yml") + yamlf = open(yfname, "w") + odict = { + "name": self.tool_name, + "owner": "fubar2", + "type": "unrestricted", + "description": "ToolFactory autogenerated tool", + "synopsis": self.args.tool_desc, + "category": "ToolFactory generated Tools", + } + yaml.dump(odict, yamlf, allow_unicode=True) + yamlf.close() + + def writeTFyml(self): + """for posterity""" + adict = {} + rargs = [ + "input_files", + "output_files", + "additional_parameters", + "selecttext_parameters", + "selectflag_parameters", + "xtra_files", + ] + args = vars(self.args) + for k in args.keys(): + if k not in rargs: + adict[k] = args.get(k, None) + else: + if adict.get(k, None): + adict[k].append(adict[k]) + else: + adict[k] = [args.get(k, None)] + adict["script"] = self.script + adict["help"] = self.helptext + yfname = os.path.join(self.repdir, "%s_ToolFactory.yml" % self.tool_name) + yf = open(yfname, "w") + yaml.dump(adict, yf) + yf.close() + + def saveTestdata(self, pname, testDataURL): + """ + may need to be ungzipped and in test folder + """ + res = 0 + localpath = os.path.join(self.tooltestd, "%s_sample" % pname) + print("#### save", testDataURL, "for", pname, "to", localpath) + if not os.path.exists(localpath): + cl = [ + "wget", + "--timeout", + "5", + "--tries", + "2", + "-O", + localpath, + testDataURL, + ] + if testDataURL.endswith(".gz"): # major kludge as usual... + gzlocalpath = "%s.gz" % localpath + cl = [ + "wget", + "-q", + "--timeout", + "5", + "--tries", + "2", + "-O", + gzlocalpath, + testDataURL, + "&&", + "rm", + "-f", + localpath, + "&&", + "gunzip", + gzlocalpath, + ] + p = subprocess.run(" ".join(cl), shell=True) + if p.returncode: + print("Got", p.returncode, "from executing", " ".join(cl)) + else: + print("Not re-downloading", localpath) + return res + + def makeTool(self): + """write xmls and input samples into place""" + if self.args.parampass == 0: + self.doNoXMLparam() + else: + self.makeXML() + if self.args.script_path and self.not_iuc: + stname = os.path.join(self.toold, os.path.split(self.sfile)[1]) + if not os.path.exists(stname): + shutil.copyfile(self.sfile, stname) + logger.info("Copied %s to %s" % (self.sfile, stname)) + for p in self.infiles: + paths = p["name"] + pname = p["CL"] + pathss = paths.split(",") + np = len(pathss) + if p.get("URL", None): + res = self.saveTestdata(pname, p["URL"]) + for i, pth in enumerate(pathss): + if os.path.exists(pth): + if np > 1: + dest = os.path.join( + self.tooltestd, "%s_%d_sample" % (p["infilename"], i + 1) + ) + else: + dest = os.path.join( + self.tooltestd, "%s_sample" % p["infilename"] + ) + shutil.copyfile(pth, dest) + logger.info("Copied %s to %s" % (pth, dest)) + else: + logger.info( + "Optional input path %s does not exist - not copied" % pth + ) + if self.extra_files and len(self.extra_files) > 0: + for xtra in self.extra_files: + fpath = xtra["fpath"] + dest = os.path.join(self.toold, xtra["fname"]) + shutil.copyfile(fpath, dest) + logger.info("Copied xtra file %s to %s" % (fpath, dest)) + shutil.copytree(self.toold, self.testdir, dirs_exist_ok=True) + + def makeToolTar(self, test_retcode=0): + """move outputs into test-data and prepare the tarball""" + excludeme = "tool_test_output" + + def exclude_function(tarinfo): + filename = tarinfo.name + return None if filename.startswith(excludeme) else tarinfo + + logger.info("makeToolTar starting with tool test retcode=%d\n" % test_retcode) + td = os.listdir(self.toold) + for f in td: + if f.startswith("tool_test_output"): + os.unlink(os.path.join(self.toold, f)) + if self.newtarpath: + tf = tarfile.open(self.newtarpath, "w:gz") + tf.add( + name=self.toold, + arcname=self.tool_name, + # filter=exclude_function, + ) + + def planemo_local_test(self): + """ + weird legacyversion error popping up again from package version upgrade in conda_util.py in the venv. + Seems ok if run as a shell script using the Galaxy installed planemo august 1st 2023 + """ + shutil.copytree(self.toold, self.testdir, dirs_exist_ok=True) + x = "%s.xml" % self.tool_name + xout = os.path.abspath(os.path.join(self.testdir, x)) + cl = [ + "planemo", + "test", + "--galaxy_admin_key", + self.GALAXY_ADMIN_KEY, + "--engine", + "external_galaxy", + "--update_test_data", + "--galaxy_url", + self.GALAXY_URL, + xout, + ] + clx = [ + "planemo", + "test", + "--galaxy_admin_key", + "[GALAXY_ADMIN_KEY]", + "--engine", + "external_galaxy", + "--update_test_data", + "--galaxy_url", + self.GALAXY_URL, + xout, + ] + logger.info("planemo_local_test executing: %s" % " ".join(clx)) + p = subprocess.run( + " ".join(cl), + timeout=90, + shell=True, + cwd=self.testdir, + capture_output=True, + check=True, + text=True, + ) + for errline in p.stderr.splitlines(): + logger.info("planemo: %s" % errline) + for errline in p.stdout.splitlines(): + logger.info("planemo: %s" % errline) + shutil.copytree(self.testdir, self.toold) + dest = self.repdir + src = self.tooltestd + logger.info("copying to %s to %s test_outs" % (src, dest)) + shutil.copytree(src, dest, dirs_exist_ok=True) + return p.returncode + + def fast_local_test(self): + """ + galaxy-tool-test -u http://localhost:8080 -a 1613612977827175424 -t tacrev -o local --publish-history + Seems to have a race condition when multiple jobs running. Works well - 15 secs or so if only onejob at a time! so job_conf fixed. + Failure will eventually get stuck. Might need a timeout in the script + """ + scrpt = os.path.join(self.args.toolfactory_dir, "toolfactory_fast_test.sh") + extrapaths = self.tooltestd + cl = ["/usr/bin/bash", scrpt, self.tool_name, extrapaths, extrapaths] + logger.info("fast_local_test executing %s \n" % (" ".join(cl))) + p = subprocess.run( + " ".join(cl), + shell=True, + cwd=self.testdir, + capture_output=True, + check=True, + text=True, + ) + for errline in p.stderr.splitlines(): + logger.info("ephemeris: %s" % errline) + for errline in p.stdout.splitlines(): + logger.info("ephemeris: %s" % errline) + shutil.copytree(self.testdir, self.toold, dirs_exist_ok=True) + dest = self.repdir + src = self.tooltestd + shutil.copytree(src, dest, dirs_exist_ok=True) + return p.returncode + + def update_toolconf(self, remove=False): + """tempting to recreate it from the local_tools directory each time + currently adds new tools if not there. + """ + + def sortchildrenby(parent, attr): + parent[:] = sorted(parent, key=lambda child: child.get(attr)) + + logger.info("Updating tool conf files for %s\n" % (self.tool_name)) + tcpath = self.local_tool_conf + xmlfile = os.path.join(self.tool_name, "%s.xml" % self.tool_name) + try: + parser = ET.XMLParser(remove_blank_text=True) + tree = ET.parse(tcpath, parser) + except ET.XMLSyntaxError: + logger.error( + "### Tool configuration update access error - %s cannot be parsed as xml by element tree\n" + % tcpath + ) + sys.exit(4) + root = tree.getroot() + hasTF = False + e = root.findall("section") + if len(e) > 0: + hasTF = True + TFsection = e[0] + if not hasTF: + TFsection = ET.Element( + "section", {"id": "localtools", "name": "Local Tools"} + ) + root.insert(0, TFsection) # at the top! + our_tools = TFsection.findall("tool") + conf_tools = [x.attrib["file"] for x in our_tools] + if not remove: + if xmlfile not in conf_tools: # new + ET.SubElement(TFsection, "tool", {"file": xmlfile}) + sortchildrenby(TFsection, "file") + tree.write(tcpath, pretty_print=True) + gi = galaxy.GalaxyInstance(url=self.GALAXY_URL, key=self.GALAXY_ADMIN_KEY) + toolready = False + now = time.time() + nloop = 5 + while nloop >= 0 and not toolready: + try: + res = gi.tools.show_tool(tool_id=self.tool_name) + toolready = True + logger.info( + "Tool %s ready after %f seconds - %s\n" + % (self.tool_name, time.time() - now, res) + ) + except ConnectionError: + nloop -= 1 + time.sleep(2) + logger.info("Connection error - waiting 2 seconds.\n") + if nloop < 1: + logger.error( + "Tool %s still not ready after %f seconds - please check the form and the generated xml for errors? \n" + % (self.tool_name, time.time() - now) + ) + return 2 + else: + return 0 + else: + if xmlfile in conf_tools: # remove + for rem in our_tools: + if rem.attrib["file"] == xmlfile: + rem.getparent().remove(rem) + self.logger.info( + "###=============== removed tool %s from %s" + % (xmlfile, tcpath) + ) + sortchildrenby(TFsection, "file") + tree.write(tcpath, pretty_print=True) + + def install_deps(self): + """ + use script to install new tool dependencies + """ + cll = [ + "sh", + "%s/install_tf_deps.sh" % self.args.toolfactory_dir, + self.tool_name, + ] + self.logger.info("Running %s\n" % " ".join(cll)) + try: + p = subprocess.run( + " ".join(cll), shell=True, capture_output=True, check=True, text=True + ) + for errline in p.stderr.splitlines(): + self.logger.info(errline) + return p.returncode + except: + return 1 + + def timenow(self): + """return current time as a string""" + return time.strftime("%d/%m/%Y %H:%M:%S", time.localtime(time.time())) + + def cheetah_escape(self, text): + """Produce entities within text.""" + cheetah_escape_table = {"$": "\\$", "#": "\\#"} + return "".join([cheetah_escape_table.get(c, c) for c in text]) + + def parse_citations(self): + """""" + if self.args.citations: + ct = open(self.args.citations, "r").read() + citations = [c.strip() for c in ct.split("**ENTRY**") if c.strip()] + citation_tuples = [] + for citation in citations: + if citation.startswith("doi"): + citation_tuples.append(("doi", citation[len("doi") :].strip())) + else: + citation_tuples.append( + ("bibtex", citation[len("bibtex") :].strip()) + ) + return citation_tuples + else: + return None + + +def main(): + """ + This is a Galaxy wrapper. + It expects to be called by a special purpose tool.xml + + """ + parser = argparse.ArgumentParser() + a = parser.add_argument + a("--nftest", action="store_true", default=False) + a("--script_path", default=None) + a("--sysexe", default=None) + a("--packages", default=None) + a("--tool_name", default="newtool") + a("--input_files", default=[], action="append") + a("--output_files", default=[], action="append") + a("--user_email", default="Unknown") + a("--bad_user", default=None) + a("--help_text", default=None) + a("--tool_desc", default=None) + a("--toolfactory_dir", default=None) + a("--tool_version", default="0.01") + a("--citations", default=None) + a("--cl_suffix", default=None) + a("--cl_prefix", default=None) + a("--cl_override", default=None) + a("--test_override", default=None) + a("--additional_parameters", action="append", default=[]) + a("--selecttext_parameters", action="append", default=[]) + a("--selectflag_parameters", action="append", default=[]) + a("--edit_additional_parameters", action="store_true", default=False) + a("--parampass", default="positional") + a("--tfcollection", default="toolgen") + a("--galaxy_root", default="/galaxy-central") + a("--collection", action="append", default=[]) + a("--include_tests", default=False, action="store_true") + a("--install_flag", action="store_true", default=False) + a("--admin_only", default=True, action="store_true") + a("--tested_tool_out", default=None) + a("--container", default=None, required=False) + a("--tool_conf_path", default="config/tool_conf.xml") # relative to $__root_dir__ + a( + "--xtra_files", + default=[], + action="append", + ) # history data items to add to the tool base directory + tfcl = sys.argv[1:] + args = parser.parse_args() + if args.admin_only: + assert not args.bad_user, ( + 'UNAUTHORISED: %s is NOT authorized to use this tool until Galaxy admin adds %s to "admin_users" in the galaxy.yml Galaxy configuration file' + % (args.bad_user, args.bad_user) + ) + assert ( + args.tool_name + ), "## This ToolFactory cannot build a tool without a tool name. Please supply one." + os.makedirs(args.tfcollection, exist_ok=True) + logfilename = os.path.join( + args.tfcollection, "ToolFactory_make_%s_log.txt" % args.tool_name + ) + logger.setLevel(logging.INFO) + fh = logging.FileHandler(logfilename, mode="w") + fformatter = logging.Formatter("%(asctime)s - %(levelname)s - %(message)s") + fh.setFormatter(fformatter) + logger.addHandler(fh) + tf = Tool_Factory(args) + tf.makeTool() + tf.writeShedyml() + # tf.writeTFyml()tf.writeTFyml() + tf.update_toolconf() + time.sleep(5) + if tf.condaenv and len(tf.condaenv) > 0: + res = tf.install_deps() + if res > 0: + logger.debug("Toolfactory installed deps failed") + logging.shutdown() + sys.exit(6) + time.sleep(2) + testret = tf.fast_local_test() # planemo_local_test() + if False and int(testret) > 0: + logger.error("ToolFactory tool build and test failed. :(") + logger.info( + "This is usually because the supplied script or dependency did not run correctly with the test inputs and parameter settings" + ) + logger.info("when tested with galaxy_tool_test. Error code:%d" % int(testret)) + logger.info( + "The 'i' (information) option shows how the ToolFactory was called, stderr and stdout, and what the command line was." + ) + logger.info( + "Expand (click on) any of the broken (red) history output titles to see that 'i' button and click it" + ) + logger.info( + "Make sure it is the same as your working test command line and double check that data files are coming from and going to where they should" + ) + logger.info( + "In the output collection, the tool xml <command> element must be the equivalent of your working command line for the test to work" + ) + logging.shutdown() + sys.exit(5) + else: + tf.makeToolTar(testret) + jcl = sys.argv[1:] + with open( + os.path.join( + args.tfcollection, "ToolFactory_%s_commandline.json" % args.tool_name + ), + "w", + ) as fout: + fout.write(" ".join(jcl)) + logging.shutdown() + + +if __name__ == "__main__": + main()
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/toolfactory.xml Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,655 @@ +<tool id="toolfactory" name="toolfactory" version="3.0" profile="22.05" > + <description>Scripts into tools v3.0</description> + <macros> + <xml name="dataColumn"> + <param name="param_dataref" type="text" value="" label="Input data name to use as source of data column names"/> + <param name="param_multiple" type="boolean" truevalue="1" falsevalue="" value = "" + label="Allow user to make multiple selections" help="default is single selection"/> + <param name="param_value" type="text" value="" label="Default column value"> + </param> + </xml> + <xml name="singleText"> + <param name="param_value" type="text" value="" label="Default text value"> + <sanitizer invalid_char="_"> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + </xml> + <xml name="singleInt"> + <param name="param_value" type="integer" value="" label="Default integer value" > + </param> + </xml> + <xml name="singleFloat"> + <param name="param_value" type="float" value="" label="Default value"> + </param> + </xml> + <xml name="singleBoolean"> + <param name="param_value" type="boolean" value="" label="Default value" /> + <param name="truevalue" type="text" value="True" label="Command line value when True" /> + <param name="falsevalue" type="boolean" value="True" label="Command line value when False" /> + </xml> + <xml name="selectText"> + <repeat name="selectTexts" title="Add each option to be presented" min="2" default="2" + help="Each text added here will also have a value to be emitted on the command line when the text is chosen"> + <param name="select_text" type="text" value="" label="Explanatory text the user will see for this choice" > + <sanitizer invalid_char="_"> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + <param name="select_value" type="text" value="" label="Value for the command line when the user selects this option"> + <sanitizer invalid_char="_"> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + </repeat> + </xml> + <xml name="selectFlag"> + <repeat name="selectFlags" title="Add mutually exclusive flag selection" min="2" default="2" + help="Supply the corresponding mutually exclusive flag as it should appear on the command line if each option is selected"> + <param name="select_text" type="text" value="" label="Explanatory text the user will see for this choice" > + </param> + <param name="select_value" type="text" value="" label="Value for the command line when the user selects this option" + help="Supply the corresponding mutually exclusive flag as it should appear on the command line if each option is selected"> + </param> + </repeat> + </xml> + <xml name="tool_metadata"> + <param name="tool_version" label="Tool Version - bump this to warn users trying to redo old analyses" type="text" + help="If you change your script and regenerate the 'same' tool, you should inform Galaxy (and users) by changing (bumping is traditional) this number"/> + <param name="tool_desc" label="Tool Synopsis" type="text" value="" + help="Supply a brief tool description for the Galaxy tool menu entry"> + </param> + <param name="help_text" label="Tool form documentation and help text for users" type="text" area="true" + value="**What it Does**" + help="Supply user documentation to appear on the new tool form as reStructured text - http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html" > + <sanitizer> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + <repeat name="citations" title="Citation"> + <conditional name="citation_type"> + <param name="type" type="select" display="radio" label="Citation Type"> + <option value="doi">DOI</option> + <option value="bibtex">BibTeX</option> + </param> + <when value="doi"> + <param name="doi" label="DOI" type="text" + help="Supply a DOI (e.g. doi: 10.1111/j.1740-9713.2007.00258.x) to be cited when this tool is used in published research." > + <sanitizer> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + </when> + <when value="bibtex"> + <param name="bibtex" label="BibTex" type="text" area="true" + help="Supply a BibTex entry that should be cited when this tool is used in published research." value="" > + <sanitizer> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + </when> + </conditional> + </repeat> + </xml> + <xml name="io"> + <section name="io" title="Input and output files" expanded="true"> + <repeat name="history_inputs" title="Inputs" min="0" + help="Input data files to pass on the command line to the executable. USE SMALL SAMPLES for the new tool's test. + Prompts will form a history item selector as input for users of this new tool"> + <param name="input_files" type="data" format="data" label="Select an input file from your history" multiple="true" + help="Note that multiple inputs can be selected if this input parameter will allow multiple selections"/> + <param name="input_formats" type="select" multiple="true" label="Select the datatype(s) that your tool/script accepts as input" + help="If your datatype is not listed here, it has to be added in galaxy's datatypes_conf.xml" value="tabular"> + <options from_parameter="tool.app.datatypes_registry.upload_file_formats"> + <column name="value" index="0"/> + </options> + </param> + <param name="input_label" type="text" value="" label="This will become the user prompt for the form so please make it informative" > + </param> + <param name="input_help" type="text" value="" label="This will become help text on the form." > + </param> + <param name="input_CL" type="text" label="Positional: ordinal integer. Argparse: argument name. STDIN if the executable/script expects it" + help="If you will pass positional parameters, enter the integer ordinal for this parameter. If Argparse style, '--' will be prepended or '-' if + single character"> + </param> + <param name="input_required" type="select" label="Input mode - optional, required, repeated optional or 1 or more repeated required."> + <option value="required" selected="true">Required single input</option> + <option value="optional">Optional single input</option> + <option value="required1">Required. 1 or more repeats</option> + <option value="optional1">Optional. 1 or more repeats</option> + </param> + </repeat> + <repeat name="history_outputs" min="0" title="Outputs" + help="New history items output by the executable to appear in the user history after the tool runs. The name will become a history item for + users of the new tool you are making containing one of it's outputs"> + <param name="history_name" type="text" label="Output Name" optional="false" + help="Name used for this output in history. No spaces. Digits and letters only please. Argparse should look for this name on the command line."> + <sanitizer invalid_char="_"> + <valid initial="string.ascii_letters,string.digits" > + <add value="_" /> + </valid> + </sanitizer> + </param> + <param name="history_label" type="text" label="Output label. Allows template substitution" value="" + help="Label used for this output - for example 'Plotlytabular $title on $input_tab.element_identifier' where variable templates are informative." > + <sanitizer> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + <param name="history_format" type="select" multiple="false" label="Select the datatype for this output" + help="If your datatype is not listed here, it has to be added in galaxy's datatypes_conf.xml" value="tabular"> + <options from_parameter="tool.app.datatypes_registry.upload_file_formats"> + <column name="value" index="0"/> + </options> + </param> + <param name="history_CL" type="text" label="Position" + help="Positional: ordinal integer or 'STDOUT' if '>' required. Ignored if argparse because output name is used. + If positional parameters, enter the integer ordinal expected for this parameter. If argparse, ignore unless STDOUT needed" value=""/> + <param name="history_test" type="text" label="Output test criteria" + help="Pass/fail decision criterion for this output compared to test generation. Accepted variants include diff:100, sim_size:100 and sim_size:0.1" + value="diff:0"/> + <repeat name="history_whens" title="Optional change_format on this data" min="0" help="ADVANCED option only!! Easy to get wrong!"> + <param name="history_when" type="text" label="Add a 'when' expression for this output so format can depend on another parameter" + help="Supply the three key=value pairs needed as shown - no quotes: input=image_format value=small_png format=png" value=""> + </param> + </repeat> + </repeat> + <repeat name="collection_outputs" title="Output Collections" min="0" + help="New history collections to appear in the user history after the tool runs. Hides outputs not needed for downstream tools such as + images and intermediate reports." default="0"> + <param name="name" type="text" label="Name" + help="for new collection with all outputs not individually passed to history outputs. No spaces! Script MUST create and fill a directory + with the same name and the tool test MUST be overwritten - see the plotter example for hints"> + </param> + <param name="kind" type="select" multiple="false" label="Select the kind of collection for this output" + help=""> + <option value="list" selected="true">List</option> + <option value="paired">Paired</option> + <option value="list:paired">List of paired</option> + </param> + <param name="label" type="text" label="Collection label. Allows template substitution" value="" + help="Label used for this output - for example 'Plotlytabular $title on $input_tab.element_identifier' where variable templates are informative." > + <sanitizer> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + <param name="discover" type="text" label="Discover datasets expression" help="__name_and_ext__ should catch all filenames with extensions" + value="__name_and_ext__"/> + </repeat> + + </section> + </xml> + <xml name="additparam"> + <section name="addparam" title="Arguments" help="Executable or script settings passed on the command line other than I/O files" expanded="true"> + <param name="edit_params" type="select" display="radio" label="Make these settings on the generated tool form user editable?" + help="If no, users will NOT be able to alter any additional parameters. If yes, these will appear on the tool form as text fields with no validation or sanitizing"> + <option value="yes" selected="true">Yes, allow user to edit all additional parameters on the generated tool form</option> + <option value="no">No - use the fixed values for all additional parameters - no user editing</option> + </param> + <repeat name="additional_parameters" title="Command Line Parameters" min="0" + help="Command line settings for the user to pass to the executable. See examples below to see how these can be parsed by scripts in the various languages"> + <param name="param_name" type="text" value="" label="Name for this parameter. Underscore, letters and digits only. No spaces allowed"> + <sanitizer invalid_char="_"> + <valid initial="string.ascii_letters,string.digits"> + <add value="_"/> + </valid> + </sanitizer> + </param> + <conditional name="ap_type"> + <param name="param_type" type="select" label="Type for this parameter"> + <option value="text" selected="true">Text string</option> + <option value="integer">Integer</option> + <option value="float">Float</option> + <option value="boolean">Boolean</option> + <option value="selecttext">Select text string</option> + <option value="selectflag">Select from a mutually exclusive list of command line flags to pass</option> + <option value="clflag">Flag - user can set. Only used for argparse parameter passing style</option> + <option value="datacolumn">Data column - user selects from an input tabular file column name/header values</option> + </param> + <when value = "text"> + <expand macro="singleText" /> + </when> + <when value = "integer"> + <expand macro="singleInt" /> + </when> + <when value = "float"> + <expand macro="singleFloat" /> + </when> + <when value = "boolean"> + <expand macro="singleBoolean" /> + </when> + <when value = "selecttext"> + <expand macro="selectText" /> + </when> + <when value = "selectflag"> + <expand macro="selectFlag" /> + </when> + <when value = "clflag"> + <param name="param_value" type="select" value="notset"> + <option value='notset'>DO NOT set this flag</option> + <option value='set'>SET this flag</option> + </param> + </when> + <when value = "datacolumn"> + <expand macro="dataColumn" /> + </when> + </conditional> + <param name="param_label" type="text" value="" label="Label for the form"> + <sanitizer> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + <param name="param_help" type="text" value="" label="Help for this parameter"> + <sanitizer> + <valid initial="string.printable" > + </valid> + </sanitizer> + </param> + <param name="param_CL" type="text" label="Positional ordinal | argparse argument name" + help="Using positional parameters, enter the integer ordinal for this parameter on the command line. Using Argparse style, + '--' will be prepended on the CL" value="" /> + <param name="param_CLprefixed" type="text" label="Override the generated default argparse name prefix if not empty - eg ----foo if needed" + help="Some targets like Planemo expect an unadorned action like 'test' before --galaxy_root." value=""> + <sanitizer invalid_char="_"> + <valid initial="string.printable" > + <remove value="'" /> + </valid> + </sanitizer> + </param> + <param name="param_repeat" type="boolean" checked="False" truevalue="1" falsevalue="0" + label="Allow user to repeat this as many times as needed." /> + </repeat> + </section> + </xml> + </macros> +<requirements> + <requirement type="package" version="3.10.12">python</requirement> + <requirement type="package" version="0.5.3">galaxyxml</requirement> + <requirement type="package" version="1.2.0">bioblend</requirement> + <requirement type="package" version="0.75.20">planemo</requirement> + <requirement type="package" version="0.10.10">ephemeris</requirement> +</requirements> + +<command detect_errors="exit_code"><![CDATA[ +#import os +#set dev_env = os.environ.get('GALAXY_DEVELOPMENT_ENVIRONMENT', '0') == '1' +#if not $__user_email__ + #set useremail = 'admin@galaxy.this' +#else + #set useremail = $__user_email__ +#end if +#if not $dev_env and ( $__user_email__ not in $__admin_users__ ) + python3 $__tool_directory__/toolfactory.py --bad_user $__user_email__ +#else + python3 $__tool_directory__/toolfactory.py + #if len(str($cl_options.cl_suffix)) > 0 +--cl_suffix "$clsuffix" + #end if + #if len(str($cl_options.cl_prefix)) > 0 +--cl_prefix "$clprefix" + #end if + #if len(str($cl_options.cl_override)) > 0 +--cl_override "$commandoverride" + #end if + #if len(str($cl_options.test_override)) > 0 +--test_override "$testoverride" + #end if + #if $deps.packages > "": + --packages "$deps.packages" + #end if + #if $deps.usescript.choosescript == "yes" +--script_path "$runscript" +--sysexe "$deps.usescript.scriptrunner" + #end if +--tool_name "$tool_name" --user_email "$useremail" --citations "$citeme" --parampass "$io_param.ppass.parampass" +--tool_desc "$tool_desc" +--tool_version "$tool_version" +--help_text "$helpme" + #if $io_param.ppass.parampass != '0' + #if str($io_param.ppass.addparam.edit_params) == "yes" +--edit_additional_parameters + #end if + #for $apar in $io_param.ppass.addparam.additional_parameters + #if $apar.ap_type.param_type=="selecttext" +--selecttext_parameters '{"name":"$apar.param_name", "label":"$apar.param_label", "help":"$apar.param_help", +"type":"$apar.ap_type.param_type","CL":"$apar.param_CL","override":"$apar.param_CLprefixed","value": [ + #for $i,$st in enumerate($apar.ap_type.selectTexts): + "$st.select_value" + #if ($i < (len($apar.ap_type.selectTexts)-1)): + , + #end if + #end for + ], "texts": [ + #for $i,$st in enumerate($apar.ap_type.selectTexts): + "$st.select_text" + #if ($i < (len($apar.ap_type.selectTexts)-1)): + , + #end if + + #end for + ] + }' + #else if $apar.ap_type.param_type=="selectflag" +--selectflag_parameters '{"name":"$apar.param_name", "label":"$apar.param_label", "help":"$apar.param_help", +"type":"$apar.ap_type.param_type","CL":"$apar.param_CL","override":"$apar.param_CLprefixed","value": [ + #for $i,$st in enumerate($apar.ap_type.selectFlags): + "$st.select_value" + #if ($i < (len($apar.ap_type.selectFlags)-1)): + , + #end if + #end for + ], "texts": [ + #for $i,$st in enumerate($apar.ap_type.selectFlags): + "$st.select_text" + #if ($i < (len($apar.ap_type.selectFlags)-1)): + , + #end if + + #end for + ] + }' + #else if $apar.ap_type.param_type=="datacolumn" +--additional_parameters '{"name": "$apar.param_name", "value": "$apar.ap_type.param_value", "label": "$apar.param_label", "help": "$apar.param_help", +"type": "$apar.ap_type.param_type","CL": "$apar.param_CL","override": "$apar.param_CLprefixed", "repeat": "$apar.param_repeat", "multiple": "$apar.ap_type.param_multiple", + "dataref": "$apar.ap_type.param_dataref"}' + #else: +--additional_parameters '{"name": "$apar.param_name", "value": "$apar.ap_type.param_value", "label": "$apar.param_label", "help": "$apar.param_help", +"type": "$apar.ap_type.param_type","CL": "$apar.param_CL","override": "$apar.param_CLprefixed", "repeat": "$apar.param_repeat"}' + #end if + #end for + #end if + #for $intab in $io_param.ppass.io.history_inputs +--input_files '{"name": "$intab.input_files", "CL": "$intab.input_CL", "format": "$intab.input_formats", "label": "$intab.input_label", +"help": "$intab.input_help", "required": "$intab.input_required"}' + #end for + #for $otab in $io_param.ppass.io.history_outputs + #if str($otab.history_label) > "" + --output_files '{"name": "$otab.history_name", "format": "$otab.history_format", "CL": "$otab.history_CL", "test": "$otab.history_test", "label": "$otab.history_label" + #else + --output_files '{"name": "$otab.history_name", "format": "$otab.history_format", "CL": "$otab.history_CL", "test": "$otab.history_test" + #end if + #if $otab.history_whens + , "when": [ + #for $i, $hw in enumerate($otab.history_whens) + "$hw.history_when" + #if ($i < (len($otab.history_whens)-1)) + , + #end if + #end for + ] + #end if + }' + #end for + #for $collect in $io_param.ppass.io.collection_outputs +--collection '{"name": "$collect.name", "kind": "$collect.kind", "discover": "$collect.discover", "label": "$collect.label"}' + #end for +--tfcollection 'toolgen' +--tested_tool_out "$untested_tool" +--nftest +--galaxy_root "$__root_dir__" +--toolfactory_dir "$__tool_directory__" + #if $cl_options.xtracond.needxtra == "yes" + #for $x in $cl_options.xtracond.xtra_files +--xtra_file '{"fpath":"$x", "fname":"$x.element_identifier"}' + #end for + #end if +#end if +]]> +</command> + <configfiles> + <configfile name="runscript"> +${deps.usescript.dynScript} + </configfile> + <configfile name="commandoverride"> +#if len(str($cl_options.cl_override).strip()) > 1: +${cl_options.cl_override} +#end if + </configfile> + <configfile name="testoverride"> +#if len(str($cl_options.test_override).strip()) > 1: +${cl_options.test_override} +#end if + </configfile> +<configfile name="clprefix"> +#if len(str($cl_options.cl_prefix).strip()) > 1: +${cl_options.cl_prefix} +#end if + </configfile> + <configfile name="clsuffix"> +#if len(str($cl_options.cl_suffix).strip()) > 1: +${cl_options.cl_suffix} +#end if + </configfile> + <configfile name="helpme"> +${help_text} + </configfile> + <configfile name="citeme"> + +#for $citation in $citations: + #if $citation.citation_type.type == "bibtex": + **ENTRY**bibtex + ${citation.citation_type.bibtex} + #else + **ENTRY**doi + ${citation.citation_type.doi} + #end if +#end for + + </configfile> + </configfiles> + <inputs> + <param name="tool_name" type="text" value="my_tool" label="New tool ID and title for outputs" + help="Toolshed repository name so lower case, digits and underscores only. Choose thoughtfully to avoid namespace clashes with other tool writers."> + <sanitizer invalid_char="_"> + <valid initial="string.ascii_lowercase,string.digits"> + <add value="_"/> + </valid> + </sanitizer> + </param> + + <section name="deps" title="Dependencies, optional script and script interpreter" expanded="true"> + + <param name="packages" type="text" value="" label="Conda dependencies as package name[:version, name:version...]. + These will always be available when this tool executes" help="Use =[ver] or :[ver] for specific version - 'bwa=0.17.0'. + Default is latest. Will be used every time the tool is (re)run. Only Conda is currently supported" /> + + <conditional name="usescript"> + <param name="choosescript" type="select" display="radio" label="Supply a script for a dependency (e.g. python/R/bash) or a system executable such as Bash" + help = "For script interpreters like Python or bash, parameters and i/o specified below must match script's expectations - i + f you pass parameters, the script must deal with them"> + <option value="no">No script required for this tool - just pass parameters on the command line to the first dependency listed above</option> + <option value="yes" selected="true">Yes, a script is ready to be pasted below</option> + </param> + <when value="no"> + <param name="dynScript" type="hidden" value="" /> + <param name="scriptrunner" type="hidden" value="" /> + </when> + <when value="yes"> + <param name="scriptrunner" type="text" value="" label="Interpreter for the script - eg bash or python. Can be one of the dependencies named + above or a system executable" help="Scripts are interpreted by the executable named here. For conda r-base, 'Rscript --vanilla' or for + conda planemo, 'planemo test' for example"> + </param> + <param name="dynScript" type="text" area="True" value="" label="Script for executable above to interpret. It can be one of the Conda dependency names" + help="Script must handle all i/o and parameters as specified below using the parameters and passing method chosen below"> + <sanitizer> + <valid initial="string.printable"/> + </sanitizer> + </param> + </when> + </conditional> + </section> + <section name="io_param" title="Data file input, output and settings forming the executable or script command line" expanded="true"> + <conditional name="ppass"> + <param name="parampass" type="select" display="radio" label="Command line parameter passing method to use"> + <option value="argparse" selected="true">Argparse: passed in the form of --clname value</option> + <option value="embed">Script has Cheetah templates for parameters embedded into the code</option> + <option value="embednfmod">Specialised embed with nf-core module pixie dust</option> + <option value="positional">Positional: Passed in the order of positional ordinals ...foo.bam bar.idx zot.xls</option> + <option value="0">Tool reads selected input file from STDIN and writes STDOUT with no parameters</option> + </param> + <when value="argparse"> + <expand macro="io" /> + <expand macro="additparam" /> + </when> + <when value="embed"> + <expand macro="io" /> + <expand macro="additparam" /> + </when> + <when value="embednfmod"> + <expand macro="io" /> + <expand macro="additparam" /> + </when> + <when value="positional"> + <expand macro="io" /> + <expand macro="additparam" /> + </when> + <when value="0"> + <expand macro="io"/> + </when> + </conditional> + </section> + <section name="cl_options" title="ADVANCED DIY MANUAL REPLACEMENT OPTIONS: Test or command line prefix, suffix or DIY command line" expanded="false" > + <param name="cl_prefix" type="text" area="True" value="" label="Prefix for generated command line. Useful for bash pre processing. + Use override below to replace completely" + help="';' separated bash commands can be used here for pre processing like renaming or copying datasets for the script - + added at start of autogenerated command line"> + <sanitizer> + <valid initial="string.printable" /> + </sanitizer> + </param> + <param name="cl_suffix" type="text" area="True" value="" label="Suffix for generated command line. Useful for bash post processing. + Use override below to replace completely" + help="';' separated bash commands can be used here for post processing - added at end of autogenerated command line" > + <sanitizer> + <valid initial="string.printable" /> + </sanitizer> + </param> + <param name="cl_override" type="text" area="True" label="Optional. Human wrought command element override XML/template - e.g. for bwa" + help="For arbitrary and artfull command lines. All i/o and parameters must be passed. Leave blank unless needed. Not for the faint of heart" value=""> + <sanitizer> + <valid initial="string.printable"/> + </sanitizer> + </param> + <param name="test_override" type="text" area="True" label="Optional. Human wrought test element override XML/template - e.g. for bwa" + help="For arbitrary and artfull scripts. Leave blank unless needed. Not for the faint of heart" value=""> + <sanitizer> + <valid initial="string.printable" /> + </sanitizer> + </param> + <conditional name="xtracond"> + <param name="needxtra" type="select" display="radio" label="Specific files from the history must be available in the tool directory" + help = "If you need a java .jar file or special data file for your script to be able to access, upload it to the history and select it here"> + <option value="no" selected="true">No special files need to be available in the tool directory for the script to use</option> + <option value="yes">Yes - some special files must be copied into the tool directory</option> + </param> + <when value="no"> + <param name="xtra_files" type="hidden" value="" /> + </when> + <when value="yes"> + <param name="xtra_files" type="data" format="data" label="Select all files from your history to add to tool directory for the script to use" multiple="true" + help="If your script needs access to a .jar or other specific permanent resource, upload it before building, so you can select it here. + All those selected history items will be added to the tool directory. That path is available at execution as $__tool_directory__, for use in the command section. + These need to be expanded and used as parameters for the script where needed: $__tool_directory__/BlastTools.jar for example"/> + </when> + </conditional> + </section> + <expand macro="tool_metadata" /> + <param name="useremail" type="hidden" value="" /> + <param name="script_path" type="hidden" value="" /> + </inputs> + <outputs> + <collection name="toolgen" type="list" label="${tool_name} generated components"> + <discover_datasets pattern="__name_and_ext__" directory="toolgen" visible="false"/> + </collection> + <data name="untested_tool" format="tgz" label = "${tool_name}_toolshed_archive"/> + </outputs> + <tests> + <test> + <param name="useremail" value="admin.galaxy.here" /> + <param name="input_files" value="input1_sample" /> + <param name="input_CL" value="1" /> + <param name="input_formats" value="txt" /> + <param name="input_label" value="input" /> + <param name="input_help" value="help" /> + <param name="tool_name" value="pyrevpos" /> + <param name="parampass" value="positional" /> + <param name="tool_version" value="0.01" /> + <param name="tool_desc" value="positional reverse" /> + <param name="help_text" value="help text goes here" /> + <param name="packages" value="python" /> + <param name="history_name" value="output2" /> + <param name="history_format" value="txt" /> + <param name="history_CL" value="2" /> + <param name="dynScript" value="import sys; inp = sys.argv[1]; outp = sys.argv[2]; inlist = open(inp,'r').readlines(); + o = open(outp,'w'); rs = [''.join(list(reversed(x.rstrip()))) for x in inlist]; o.write('\n'.join(rs)); o.close()" /> + <param name="choosescript" value="yes" /> + <param name="script_path" value="$runscript" /> + <output name="untested_tool" file="pyrevpos_not_tested.toolshed_sample" ftype="tgz" compare="sim_size" delta_frac="0.1" /> + </test> + </tests> + <help> + +**Details and attribution** +(see GTF_) + +**Local Admins ONLY** +Only users with emails in the local admin_user configuration setting in config/galaxy.yml can run this tool. + +**If you find a bug** +Please raise an issue, or even better, submit a pull request fixing it, on the github repository GTF_ + +**What it does** +This tool contains an automated code generator, and creates normal, workflow compatible Galaxy tools as Toolshed ready archives. The +new tool is immediately installed and available for use - a page refresh will be needed to see the new tool in the "Local" tool section. + +Generated tools can use existing Conda packages. These become requirements for optional scripts pasted into this tool form. +Pasted scripts *cannot be adjusted* by the downstream user. + +Any number of parameters can be built into the new tool form for passing in to the script or executable at runtime. +These can be editable by the downstream user or baked in. + +A new tarball compatible with any Galaxy toolshed is created in your history, including a test based on the supplied default parameter +values and input history datasets. + +.. class:: warningmark + +**Note to system administrators** +This tool offers *NO* built in protection against malicious scripts. It should only be installed on private/personnal Galaxy instances. +Admin_users will have the power to do anything they want as the Galaxy user if you install this tool. + +.. class:: warningmark + +**Use on public servers** is STRONGLY discouraged for obvious reasons + +The tools generated by this tool will run just as securely as any other normal installed Galaxy tool but like any other new tools, +should always be checked carefully before installation. We recommend that you follow the good code hygiene practices associated with safe toolshed practices. + + +Paper_ + +*Licensing* + +Copyright Ross Lazarus May 2012 +Licensed under the MIT_ licence. + +.. _MIT: https://mit-license.org/ +.. _GTF: https://github.com/fubar2/galaxy_tf_overlay +.. _Paper: https://academic.oup.com/bioinformatics/article/28/23/3139/192853 + + + </help> + <citations> + <citation type="doi">10.1093/bioinformatics/bts573</citation> + </citations> +</tool> + +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/toolfactory/toolfactory_fast_test.sh Thu Feb 22 10:48:01 2024 +0000 @@ -0,0 +1,11 @@ +GALAXY_URL=http://localhost:8080 +GALAXY_VENV=/home/ross/rossgit/galaxytf231/.venv +API_KEY=1718977735397126400 +API_KEY_USER=995248011247121408 +# for test@bx.psu.edu user +# for sed to edit at installation +# must pass toolname outdir as cl params in that order... +# shows api keys do uncomment for debugging if you must +# echo "toolfactory_fast_test.sh: galaxy-tool-test -u $GALAXY_URL -a $API_KEY -k $API_KEY_USER -t $1 -o $2 --test-data $3" +galaxy-tool-test -u $GALAXY_URL -a $API_KEY -k $API_KEY_USER -t $1 -o $2 --test-data $3 --publish-history +