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
第一步,找到项目文件下的 .csprojc 文件,用文本编辑器打开它,并找到下面这行: | |
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | |
把下面的 XML 粘贴到文件中,然后保存并在 Visual Studio 中重载: | |
<Target Name="AfterResolveReferences"> | |
<ItemGroup> | |
<EmbeddedResource Include="@(ReferenceCopyLocalPaths)" Condition="'%(ReferenceCopyLocalPaths.Extension)' == '.dll'"> | |
<LogicalName>%(ReferenceCopyLocalPaths.DestinationSubDirectory)%(ReferenceCopyLocalPaths.Filename)%(ReferenceCopyLocalPaths.Extension)</LogicalName> | |
</EmbeddedResource> | |
</ItemGroup> |
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
第一步,找到项目文件下的 .csprojc 文件,用文本编辑器打开它,并找到下面这行: | |
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | |
把下面的 XML 粘贴到文件中,然后保存并在 Visual Studio 中重载: | |
<Target Name="AfterResolveReferences"> | |
<ItemGroup> | |
<EmbeddedResource Include="@(ReferenceCopyLocalPaths)" Condition="'%(ReferenceCopyLocalPaths.Extension)' == '.dll'"> | |
<LogicalName>%(ReferenceCopyLocalPaths.DestinationSubDirectory)%(ReferenceCopyLocalPaths.Filename)%(ReferenceCopyLocalPaths.Extension)</LogicalName> | |
</EmbeddedResource> | |
</ItemGroup> |
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
#pragma once | |
namespace cyh { | |
template<class T> | |
class SmartPtr; | |
template <typename T> | |
class U_Ptr; | |
template <typename T> | |
class U_Ptr | |
{ |
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 com.cyhone; | |
import java.text.SimpleDateFormat; | |
import java.util.Calendar; | |
import java.util.Date; | |
import java.util.concurrent.TimeUnit; | |
/** | |
* @author cyhone | |
* @date 2017/3/28 |
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
class NetTimeException : Exception | |
{ | |
public string msg; | |
public long time; | |
public NetTimeException(string msg, long time) | |
{ | |
this.msg = msg; | |
this.time = time; | |
} | |
} |
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
# coding=utf-8 | |
import os | |
basedir = './corn' | |
whitelist = ['cpp', 'h'] | |
def get_files_in_dir(basedir): | |
filelists = [] | |
for parent,dirnames,filenames in os.walk(basedir): | |
for filename in filenames: |
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
import json | |
def load_from_url(): | |
with open('db.json') as f: | |
return json.load(f) | |
def mime_type_to_var(mime_type): | |
return mime_type.upper().replace("+", "_").replace("/","_").replace("-","_").replace(".","_") | |
def print_lines(file, lines): |