Browse Source

PowerShell example on Welcome page.

pull/20/head
Pēteris Caune 9 years ago
parent
commit
0cf4e5c9df
4 changed files with 11 additions and 0 deletions
  1. +2
    -0
      hc/front/management/commands/pygmentize.py
  2. +2
    -0
      templates/front/snippets/powershell.html
  3. +1
    -0
      templates/front/snippets/powershell.txt
  4. +6
    -0
      templates/front/welcome.html

+ 2
- 0
hc/front/management/commands/pygmentize.py View File

@ -20,4 +20,6 @@ class Command(BaseCommand):
_process("crontab.txt", "crontab.html", lexers.BashLexer()) _process("crontab.txt", "crontab.html", lexers.BashLexer())
_process("python.txt", "python.html", lexers.PythonLexer()) _process("python.txt", "python.html", lexers.PythonLexer())
_process("php.txt", "php.html", lexers.PhpLexer()) _process("php.txt", "php.html", lexers.PhpLexer())
_process("powershell.txt", "powershell.html",
lexers.shell.PowerShellLexer())
_process("node.txt", "node.html", lexers.JavascriptLexer()) _process("node.txt", "node.html", lexers.JavascriptLexer())

+ 2
- 0
templates/front/snippets/powershell.html View File

@ -0,0 +1,2 @@
<div class="highlight"><pre><span class="nb">Invoke-RestMethod</span> <span class="n">{{ ping_url }}</span>
</pre></div>

+ 1
- 0
templates/front/snippets/powershell.txt View File

@ -0,0 +1 @@
Invoke-RestMethod PING_URL

+ 6
- 0
templates/front/welcome.html View File

@ -50,6 +50,9 @@
<li class="hidden-xs"> <li class="hidden-xs">
<a href="#browser" data-toggle="tab">Browser</a> <a href="#browser" data-toggle="tab">Browser</a>
</li> </li>
<li class="hidden-xs">
<a href="#powershell" data-toggle="tab">PowerShell</a>
</li>
<li class="hidden-xs"> <li class="hidden-xs">
<a href="#email" data-toggle="tab">Email</a> <a href="#email" data-toggle="tab">Email</a>
</li> </li>
@ -73,6 +76,9 @@
<div class="tab-pane" id="browser"> <div class="tab-pane" id="browser">
{% include "front/snippets/browser.html" %} {% include "front/snippets/browser.html" %}
</div> </div>
<div class="tab-pane" id="powershell">
{% include "front/snippets/powershell.html" %}
</div>
<div class="tab-pane" id="email"> <div class="tab-pane" id="email">
<div class="instructions"> <div class="instructions">
As an alternative to HTTP/HTTPS requests, As an alternative to HTTP/HTTPS requests,


Loading…
Cancel
Save