This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$data = file_get_contents('https://example.com/mt/mt-data-api.cgi/v1/sites/1/entries'); | |
$entries = json_decode($data); | |
foreach ($entries as $e) { | |
// Do stuff | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$entries = include('https://example.com/mt/mt-data-api.cgi/v1/sites/1/entries.php'); | |
foreach ($entries as $e) { | |
// Do stuff | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
<<__KNOWN_HOSTS___ | |
github.com ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ== | |
__KNOWN_HOSTS___ | |
exec ssh -o UserKnownHostsFile="$0" -o CheckHostIP=no "$@" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use strict; | |
use warnings; | |
BEGIN { | |
use Cwd qw(getcwd); | |
$ENV{MT_HOME} ||= getcwd; | |
} | |
use lib "$ENV{MT_HOME}/lib", "$ENV{MT_HOME}/extlib"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use lib $ENV{MT_HOME} ? "$ENV{MT_HOME}/lib" : 'lib'; | |
use lib $ENV{MT_HOME} ? "$ENV{MT_HOME}/extlib" : 'extlib'; | |
use lib $ENV{MT_HOME} ? "$ENV{MT_HOME}/t/lib" : 't/lib'; | |
BEGIN { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: P-M-ServerStatus-Lite | |
version: 1.00 | |
plack_middlewares: | |
- name: ServerStatus::Lite | |
options: | |
- key: path | |
value: /server-status | |
- key: allow | |
value: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package Plack::Middleware::MT::AliasedSearch; | |
use strict; | |
use warnings; | |
use utf8; | |
use parent 'Plack::Middleware'; | |
use Plack::Util::Accessor qw(recipes); | |
sub call { | |
my ( $self, $env ) = @_; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CGIPath /mt/ | |
SearchScript search |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: P-M-AliasedSearch | |
version: 1.00 | |
description: This plugin creates aliases to search-parameter. | |
plack_middlewares: | |
- name: MT::AliasedSearch | |
options: | |
- key: recipes | |
value: | |
- from: food |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: P-M-DebugRequestParams | |
version: 1.00 | |
plack_middlewares: | |
- name: DebugRequestParams | |
condition: sub { MT->config->DebugMode } | |
apply_to: | |
- all |