Skip to content

Instantly share code, notes, and snippets.

@robertbiswas
Last active August 23, 2018 22:50
Show Gist options
  • Save robertbiswas/6d0bbe3207d8f8386f55b6861a4d1126 to your computer and use it in GitHub Desktop.
Save robertbiswas/6d0bbe3207d8f8386f55b6861a4d1126 to your computer and use it in GitHub Desktop.
Snippet for Sublime Text 3 : Standard Plugin Information
<snippet>
<content><![CDATA[
/*
Plugin Name: ${1:plugin-name}
Plugin URI: http://plugins.robertbiswas.com/${3:text-domain}
Description: ${4:Description}
Version: 1.0
Author: Robert Biswas
Author URI: http://robertbiswas.com
License: GPL2
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ${3:text-domain}
Domain Path: /languages
*/
defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
function ${5:prefix}_load_text_domain(){
load_plugin_textdomain( '${3:text-domain}', false, dirname(__FILE__)."/languages" );
}
add_action( 'plugins_loaded', '${5:prefix}_load_text_domain' );
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>new-plugin-rb</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.php</scope>
<!-- Optional: Description to show in the menu -->
<description>Standard Plugin Information</description>
</snippet>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment