最近幫老婆大人換手機,順便記錄一下用鈦備份來完整備份/還原 Line 聊天記錄的心得。
※參考文章:使用 Titanium Backup 備份 Android ID 和多機一Line&一機多Line&Line備份還原
※參考文章:使用 Titanium Backup 備份 Android ID 和多機一Line&一機多Line&Line備份還原
{
"cmd": ["python3", "-u", "$file"],
"file_regex": "^[ ]*File \"(...*?)\", line ([0-9]*)",
"selector": "source.python"
}
mattias@mattias-Desktop:~$ gem install rails
Fetching: thread_safe-0.3.5.gem (100%)
Successfully installed thread_safe-0.3.5
Fetching: minitest-5.8.1.gem (100%)
Successfully installed minitest-5.8.1
Fetching: tzinfo-1.2.2.gem (100%)
Successfully installed tzinfo-1.2.2
Fetching: i18n-0.7.0.gem (100%)
Successfully installed i18n-0.7.0
Fetching: activesupport-4.2.4.gem (100%)
Successfully installed activesupport-4.2.4
Fetching: rails-deprecated_sanitizer-1.0.3.gem (100%)
Successfully installed rails-deprecated_sanitizer-1.0.3
Fetching: mini_portile-0.6.2.gem (100%)
Successfully installed mini_portile-0.6.2
Fetching: nokogiri-1.6.6.2.gem (100%)
Building native extensions. This could take a while...
ERROR: Error installing rails:
ERROR: Failed to build gem native extension.
/home/mattias/.rvm/rubies/ruby-2.2.3/bin/ruby -r ./siteconf20150930-14059-do0e7v.rb extconf.rb
checking if the C compiler accepts ... *** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/home/mattias/.rvm/rubies/ruby-2.2.3/bin/$(RUBY_BASE_NAME)
--help
--clean
/home/mattias/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/mkmf.rb:456:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /home/mattias/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/mkmf.rb:571:in `block in try_compile'
from /home/mattias/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/mkmf.rb:522:in `with_werror'
from /home/mattias/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/mkmf.rb:571:in `try_compile'
from extconf.rb:80:in `nokogiri_try_compile'
from extconf.rb:87:in `block in add_cflags'
from /home/mattias/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/mkmf.rb:619:in `with_cflags'
from extconf.rb:86:in `add_cflags'
from extconf.rb:337:in `'
extconf failed, exit code 1
Gem files will remain installed in /home/mattias/.rvm/gems/ruby-2.2.3/gems/nokogiri-1.6.6.2 for inspection.
Results logged to /home/mattias/.rvm/gems/ruby-2.2.3/extensions/x86_64-linux/2.2.0/nokogiri-1.6.6.2/gem_make.out
JDK Required: 'tools.jar' seems to be not in Studio classpath.
Please ensure JAVA_HOME points to JDK rather than JRE.
JAVA_HOME=~/Develop/sdks/jdk
NAME
iconv - Convert encoding of given files from one encoding to another
SYNOPSIS
iconv -f encoding [-t encoding] [inputfile]...
DESCRIPTION
The iconv program converts the encoding of characters in inputfile, or from the standard input if no filename is specified, from one coded character set to another. The result is
written to standard output unless otherwise specified by the --output option.
--from-code, -f encoding
Convert characters from encoding.
--to-code, -t encoding
Convert characters to encoding. If not specified the encoding corresponding to the current locale is used.
--list, -l
List known coded character sets.
-c Omit invalid characters from output.
--output, -o file
Specify output file (instead of stdout).
--silent, -s
Suppress warnings, but not errors.
--verbose
Print progress information.
--help, -?
Give help list.
--usage
Give a short usage message.
--version, -V
Print program version.
假設來源檔案為 source.txt,轉換成 utf-8 後的檔名叫 target.txt,那麼就在命令列輸入下列內容:iconv -f gb2312 -t utf-8 source.txt --output target.txt
搞定收工!