This file contains 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
/** | |
* Copyright 2016 SmartThings | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except | |
* in compliance with the License. You may obtain a copy of the License at: | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software distributed under the License is distributed | |
* on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License |
This file contains 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
/// This is a marker type that allows us to mark a Vec<u8> as one that should be converted into | |
/// a Lua string type. | |
#[derive(Clone, Debug)] | |
pub struct ByteString(Vec<u8>); | |
impl From<Vec<u8>> for ByteString { | |
fn from(vec: Vec<u8>) -> Self { | |
ByteString(vec) | |
} | |
} |
This file contains 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
;FFMETADATA | |
# | |
# Apply this file with: ffmpeg -i Mark_twain_The_Complete_Novels.m4a -i Mark_twain_The_Complete_Novels.ffmeta -map_metadata 1 -codec copy Mark_twain_The_Complete_Novels_With_Metadata.m4a | |
# | |
title=Mark Twain: The Complete Novels | |
author=Mark Twain | |
narrator=Lee Howard | |
[CHAPTER] | |
TIMEBASE=1/1000 | |
START=0 |
This file contains 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
local socket = require "socket" | |
local http = require "socket.http" | |
local ltn12 = require "ltn12" | |
--[[ | |
local log = require "log" | |
local xml2lua = require "xml2lua" | |
local xml_handler = require "xmlhandler.tree" | |
--]] | |
-- find element of nested tables, returns nil if any part of the path can't be resolved |
This file contains 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
-- | |
-- Note: run with `busted packunpackit.lua` | |
-- | |
local havecosock, cosock = pcall(require, "cosock") | |
local socket = require "socket" | |
local pack = table and table.pack or pack | |
local unpack = table and table.unpack or unpack |
OlderNewer