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
| let () = | |
| let sock = Unix.socket Unix.PF_INET Unix.SOCK_STREAM 0 in | |
| let address = Unix.inet_addr_of_string "127.0.0.1" in | |
| let socket_address = Unix.ADDR_INET (address, 22) in | |
| Unix.connect sock socket_address; | |
| let buffer = Bytes.create 1024 in | |
| let len = Unix.read sock buffer 0 (Bytes.length buffer) in | |
| Printf.printf "%d %s" len (Bytes.to_string buffer) |
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 main | |
| import ( | |
| "bytes" | |
| "fmt" | |
| "io" | |
| "log" | |
| "net" | |
| "regexp" | |
| "strings" |
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; | |
| use Getopt::Long; | |
| GetOptions("p|pipeline" => \(my $pipeline), | |
| "h|help" => \(my $help)); | |
| sub usage($) { |
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 python | |
| import sys | |
| import os | |
| import re | |
| data = sys.stdin.readlines() | |
| for line in data: | |
| url,name = re.compile("[\s\t]+").split(line.rstrip()) | |
| # https://github.com/oopsguy/m3u8 使用这个 golang 写的小工具来下载 m3u8 链接 |
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 main | |
| import ( | |
| "flag" | |
| "log" | |
| "os" | |
| "os/exec" | |
| "path/filepath" | |
| "strings" | |
| "sync" |
OlderNewer