All Projects → itgoyo → Logtofile

itgoyo / Logtofile

Licence: gpl-3.0
Android一个简单实用把Log日志打印到手机本地文件,可以自行取出来上传到服务器开源代码

Programming Languages

java
68154 projects - #9 most used programming language

Labels

Projects that are alternatives of or similar to Logtofile

Serverless Es Logs
A Serverless plugin to transport logs to ElasticSearch
Stars: ✭ 51 (-31.08%)
Mutual labels:  log, logger
Logger
Simple logger with stores inspector
Stars: ✭ 58 (-21.62%)
Mutual labels:  log, logger
Eylogviewer
A simple viewer to see your app's logs on your iDevice in realtime.
Stars: ✭ 16 (-78.38%)
Mutual labels:  log, logger
Cocoadebug
iOS Debugging Tool 🚀
Stars: ✭ 3,769 (+4993.24%)
Mutual labels:  log, logger
Signale
Highly configurable logging utility
Stars: ✭ 8,575 (+11487.84%)
Mutual labels:  log, logger
Objectlogger
A powerful and easy-to-use operational logging system that supports analysis of changes in object properties. 强大且易用的操作日志记录系统,支持对象属性的变化分析。
Stars: ✭ 378 (+410.81%)
Mutual labels:  log, logger
Gollum
An n:m message multiplexer written in Go
Stars: ✭ 883 (+1093.24%)
Mutual labels:  log, logger
printer
A fancy logger yet lightweight, and configurable. 🖨
Stars: ✭ 65 (-12.16%)
Mutual labels:  log, logger
Logcustom
A simple log customization tool based on golang 一个基于golang简单的日志定制化工具
Stars: ✭ 46 (-37.84%)
Mutual labels:  log, logger
Activity
A PHP API to log anything anywhere
Stars: ✭ 44 (-40.54%)
Mutual labels:  log, logger
esp-logger
An Arduino library providing a minimal interface to log data on flash memory and SD cards with ESP8266 and ESP32
Stars: ✭ 40 (-45.95%)
Mutual labels:  log, logger
Yii2 Psr Log Target
Yii 2.0 log target that is able to write messages to PSR-3 compatible logger
Stars: ✭ 58 (-21.62%)
Mutual labels:  log, logger
gxlog
A concise, functional, flexible and extensible logger for go.
Stars: ✭ 65 (-12.16%)
Mutual labels:  log, logger
Plog
Portable, simple and extensible C++ logging library
Stars: ✭ 1,061 (+1333.78%)
Mutual labels:  log, logger
horse-logger
Middleware for access logging in HORSE
Stars: ✭ 25 (-66.22%)
Mutual labels:  log, logger
Laravel Log
Simple API to write logs for Laravel.
Stars: ✭ 19 (-74.32%)
Mutual labels:  log, logger
polog
Логирование должно быть красивым
Stars: ✭ 26 (-64.86%)
Mutual labels:  log, logger
ip-logger
📇 When someone clicks the link, you will receive their IP and other information via telegram.
Stars: ✭ 0 (-100%)
Mutual labels:  log, logger
Loglevelnext
A modern logging library for Node.js that provides log level mapping to the console
Stars: ✭ 33 (-55.41%)
Mutual labels:  log, logger
Logutils
More convenient and easy to use android Log manager
Stars: ✭ 1,035 (+1298.65%)
Mutual labels:  log, logger

LogToFile

↓支持一下

GitHub stars GitHub forks GitHub watchers GitHub followers  

Android a simple and practical to print to local phone logs Log files open source

The log file is written to the tools, the priority SD card -> external memory -> internal storage, in order to automatically select the three

Instructions:

1: Initialization FileLogUtils.init (Context);

2: Use FileLogUtils.write (your Log information);

Log File Path:

If the SD card or external memory exists, the SD \ Android \ data \ package name \ files \ Log \ logs.txt

If there is an SD card or external memory, then \ data \ data \ package name \ files \ Log \ logs.txt

Before using this square to remember to initialize

FileLogUtils.init (mContexet); 

then

FileLogUtils.write("yourlog");


Android一个简单实用把Log日志打印到手机本地文件开源代码

把日志写入到文件的工具类,优先顺序 SD卡->外部存储->内部存储,三者按顺序自动选择

使用方法:

  • 方法一

1:初始化 FileLogUtils.init(Context);

2:使用 FileLogUtils.write(你的Log信息);

日志文件路径:

若存在SD卡或者外部存储,则在 SD\Android\data\包名\files\Log\logs.txt

若不存在SD卡或者外部存储,则在 \data\data\包名\files\Log\logs.txt

在使用此方前要记得先初始化

LogToFileUtils.init(mContexet);//最好是在项目的Application配置这样子就不用每次都再设置一次了

然后调.write方法写手机本地文件

举个例子

public class MainActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        LogToFileUtils.init(this); //初始化

        LogToFileUtils.write("sample text");//写入日志
    }
}

  • 方法二

Step 1. Add the JitPack repository to your build file

Add it in your root build.gradle at the end of repositories:

allprojects {
		repositories {
			...
			maven { url 'https://jitpack.io' }
		}
	}

Step 2. Add the dependency

dependencies {
	        compile 'com.github.itgoyo:LogToFile:v1.0'
	}

LICENSE

源代码在 GPL v3 协议下发布, 使用前, 请确保你了解这个协议!
如有特殊协议方面的请求, 可以与我沟通: [email protected]

=======

GNU General Public Licence (GPL)  
GPL 保证了所有开发者的权利, 
同时为使用者提供了足够的复制,分发,修改的权利: 

可自由复制  
你可以将软件复制到你的电脑,你客户的电脑,或者任何地方。复制份数没有任何限制。

可自由分发  
在你的网站提供下载,拷贝到U盘送人,或者将源代码打印出来从窗户扔出去(环保起见,请别这样做)。

可以用来盈利
你可以在分发软件的时候收费,但你必须在收费前向你的客户提供该软件的 GNU GPL  
许可协议,以便让他们知道,他们可以从别的渠道免费得到这份软件,以及你收费的理由。  


可自由修改  
如果你想添加或删除某个功能,没问题,如果你想在别的项目中使用部分代码,  
也没问题,唯一的要求是,使用了这段代码的项目也必须使用 GPL 协议。  
  
需要注意的是,分发的时候,需要明确提供源代码和二进制文件,  
另外,用于某些程序的某些协议有一些问题和限制,  
你可以看一下 @PierreJoye 写的 Practical Guide to GPL Compliance 一文。  
  
使用 GPL 协议,你必须在源代码代码中包含相应信息,以及协议本身。  
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].