Skip to content

Instantly share code, notes, and snippets.

if msg_uids:
server.uid("COPY", msg_uids, INBOX_FOLDER)
server.uid("STORE", msg_uids, "+FLAGS.SILENT", r"(\Deleted)")
server.uid("EXPUNGE", msg_uids)
TB
SCRWIN001-5EFB-R1JJ-AWJC-40SG-50Q1
G3WFE8-TECB-A132ZE-QG7Q-3040C2
61QC04-QHK5-1RJJFB-2C22-WW5C3A NRK362-T768-UUT6G4-B6VZ-Z7G8JF
private static boolean isParentOf(char[] folderName, char[] fileName) {
if (folderName.length >= fileName.length) {
return false;
}
if (fileName[folderName.length] != '\\' && fileName[folderName.length] != '/') {
return false;
}
for (int i = folderName.length - 1; i >= 0; i--) {
if (folderName[i] != fileName[i]) {
return false;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
namespace RoslynDemo
@barik
barik / token
Created February 21, 2015 00:55
{
"WARC-Record-ID": "0028b23e-9d4d-462a-9636-0ac7281f75ea",
"Tokens": [
"analyses",
"cbp",
"cd",
"code",
"collection",
"com",
"container",
{
"Tika-Content-Type": "text/plain",
"Tika-Extension": ".txt",
"Digest": "sha1:19dfef9ddbc1ab66c351b83caadf1ce35415c0bf",
"WARC-Record-ID": "<urn:uuid:00039cab-5ec6-4833-980f-c7c114399674>",
"Length": 326
}
package net.barik.spreadsheet;
import org.apache.commons.io.IOUtils;
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Mapper;
import org.json.JSONObject;
import java.io.*;
package net.barik.spreadsheet;
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.conf.Configured;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Job;
import org.apache.hadoop.mapreduce.lib.input.NLineInputFormat;
import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat;
import org.apache.hadoop.util.Tool;
private static boolean shouldIgnoreOptionalProblems(char[][] folderNames, char[] fileName) {
if (folderNames == null || fileName == null) {
return false;
}
for (int i = 0, max = folderNames.length; i < max; i++) {
char[] folderName = folderNames[i];
if (isParentOf(folderName, fileName)) {
return true;
}
}
tbarik@tbarik0:/google/src/cloud/tbarik/rs_kernel/google3$ fileutil ls -l /cns/pe-d/home | grep yodalog
drwxrwxr-x 1 danielvd empty 0 2014/07/24 08:36:53 /cns/pe-d/home/yodalog