Working directories
1 | i=/media/ht/ht_5T/Work/Projects/NFE/Publication/Draft/Submission |
Image testing
GIF displayed well.
1 | ![](Test.gif) |
Hyperlink testing
1 | ![](https://img.utdstc.com/screen/13/es-file-explorer-020.jpg:200) |
1 | i=/media/ht/ht_5T/Work/Projects/NFE/Publication/Draft/Submission |
GIF displayed well.
1 | ![](Test.gif) |
Hyperlink testing
1 | ![](https://img.utdstc.com/screen/13/es-file-explorer-020.jpg:200) |
1 | cp /media/ht/ht_5T/Work/Projects/Other_Projects/Coronavirus_Project/Ref/Vaccine/20210114/*.* ftp://192.168.1.3:2121/ |
/media/ht/ht_5T/Work/Projects/Other_Projects/Coronavirus_Project/Ref/Vaccine/20210114
1 | ftp username:password@my.domain.com |
1 | ftp://ht@192.168.1.6:2121/Documents/Study/COVID-19 |
1 | ![Testing](/Figures/Sample.jpg) |
Hotel.jpg
.1 | {% asset_img Hotel.jpg This is an image %} |
Image document duplicated in the directory of 2021/01/17/20210117/
.
1 | i=/media/ht/ht_5T/Work/Projects/Herpesvirus_Project/EBV_Clinic/Budgets |
tags: [A, B, C]
以上的中括号是必须的,逗号用于分割多个Tag。
printf
替代echo
的活用Solve the problem of line breaks.
变音魔术师 from Google Play
1 | # HPV30 |
1 | setsid /usr/bin/google-chrome-stable %U https://hotliu.github.io/ |
1 | i=/media/ht/ht_5T/Work/References/Important_Journals/Not_Classified |
1 | setsid firefox http://192.168.1.7:8000/ |
Vaccine-related publications
1 | i=/media/ht/ht_5T/Work/Projects/Other_Projects/Coronavirus_Project/Ref/Vaccine/20210114 |
1 | i=/media/ht/ht_5T/Work/Projects/Other_Projects/Coronavirus_Project/Ref/Vaccine/20210114 |
1 | i=/media/ht/ht_5T/Work/Funding/2017_重大专项/Management/Meeting/20201210/Submission/ |
Manufacture | Class | Phase | Status |
---|---|---|---|
CanSino | Ad5 | 3 | Limited use in cn |
SinoPharm | Inactivated | 3 | Approved in China, U.A.E., Bahrain. Emergency use in Egypt. |
Sinovac | Inactivated | 3 | Limited use in China. |
China | Sinopharm-Wuhan | Inactivated | 3 |
1 | i=/media/ht/ht_5T/Work/Funding/2017_重大专项/Management/Meeting/20201210/Submission/ |
1 | i=/media/ht/ht_5T/Stored_Softs/Backup/Notability |
1 | cd /media/ht/ht_5T/Stored_Softs/Backup/Notability/email |
01 02 03 06 08-10
12 13 14 15 16 17 18 19 20
21 22 23 24 25 26 27 28 29 30
31 32 33 34 35 36 37 38 39 40
41 42 43 44 45 46 47 48 49 50
51 52 53
1 | cd /media/ht/ht_5T/Stored_Softs/Backup/Notability/email |
01 02 03 06 08-10
12 13 14 15 16 17 18 19 20
21 22 23 24 25 26 27 28 29 30
31 32 33 34 35 36 37 38 39 40
41 42 43 44 45 46 47 48 49 50
51 52 53
1 | exiftool -r "-FileName<CreateDate" -d "%Y-%m-%d_%H-%M-%S - %%f.%%e" 1504802408055.mp4 |
告别谷歌应该是暂时的,实在无法忍受因为Google Calendar而反复的FQ。2021年开始使用Microsoft的三件宝:
Obsidian.md
提供了一种构建知识网络的方法,网络构建与日志(流水帐)类记录是矛盾的。特别是针对旧的记录的回溯,可能更是麻烦。可能电子化的Zettelkasten(方案,能够解决类似
.bashrc
editing1 | alias D='mate-terminal --geometry=80x24+600+500 --working-directory=${HOME}/Documents; exit' |
1 | alias D='mate-terminal --geometry=80x24+10+100 --working-directory=${HOME}/Documents; exit' |
1 | sudo apt install flatpak |
1 | subl /media/ht/ht_5T/Management/Blog/README.md |
1 | alias Hexo='cd /media/${USER}/ht_5T/Management/Blog/Blog; hexo clean; hexo g; hexo d' |
以下链接,没有实施。
./find_in_pdf.docx
./List_of_PDF_Editing_tools_for_Ubuntu.html
./pdftk_Learning.docx
1 | i=large.pdf |
I had the same problem and found two different solutions (see this thread for more details). Both reduced the size of my uncompressed PDF dramatically.
1 | i=input.pdf |
1 | i=input.pdf |
Edit: I just discovered another option (for lossless compression), which avoids the nasty gs command. qpdf is a neat tool that converts PDFs (compression/decompression, encryption/decryption), and is much faster than the gs command:
Ref
1 | for Input in *.pdf; do gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.6 -dPDFSETTINGS=/ebook -dNOPAUSE -dQUIET -dBATCH -sOutputFile="${Input%.pdf}.PDF" "${Input}"; done |
1 | for i in *.pdf; do mv ${i} `pdfinfo ${i} | grep "^Title\:\ " | sed "s/Title: //" | sed 's/\,/\_/g; s/\:/\_/g; s/\ /\_/g' | sed 's/\_\_/\_/g'`.pdf; done |
1 | convert *.png target.pdf |
遇到一个例子,无法直接使用下列命令将bmp文件直接转为pdf文件。这些命令涉及:
bmp文件如下:
1 | /media/ht/ht_5T/Work/References/Tech/DNA_Amplification/Isothermal_Amp/RCA_Ref/RCA_Ref_4/RCA产物的大小/AFM/Atomic_force_microscopy_analysis_of_RCA_of_plasmid_DNA/Templiphi-Time_course.bmp |
1 | convert 1.bmp 1.pdf |
1 | mogrify -format jpg 1.bmp # output, 1.jpg |
1 | ls -1 ./*.jpg | xargs -L1 -I {} img2pdf {} -o {}.pdf |
1 | tiff2pdf -j -o file_name.pdf file_name.tiff |
.djvu
1 | sudo apt install djview |
1 | djvulibre-bin libdjvulibre21 okular-extra-backends evince libevdocument3 libevview3 |
1 | sudo apt-get install libtiff-tools |
1 | ddjvu -format=pdf file_name.djvu file_name.pdf |
epub
1 | exiftool *.epub | grep 'Package Metadata Title' | awk -F': ' '{print $2$3$4}' | sed 's/\*/\_/; s/\//\_/; s/\ /\_/g' | sed 's/\_\_/\_/g' > 1.list |
1 | ############################################### |
1 | # This will work for doc as well as docx files. |
1 | # |
pdftotext[^pdftotext]
[^pdftotext]: How to Convert a PDF File to Editable Text Using the Command Line in Linux
1 | pdftotext 1.pdf 1.txt |
pdftk
1 | pdftk 1.pdf 2.pdf 3.pdf cat output 123.pdf |
5 Easy & Effective Ways to Edit PDF Documents on Linux
How to install pdftk on Ubuntu 18.04 Bionic? - Ask Ubuntu
libgcj-common (download: https://packages.ubuntu.com/artful/libgcj-common)
libgcj17 (download: https://packages.ubuntu.com/artful/libgcj17)
pdftk, also from artful repo (download: https://packages.ubuntu.com/artful/pdftk)
libgcj-common
libgcj17
pdftk
1 | sudo gdebi /media/ht/ht_5T/Stored_Softs/Linux_Softs/Not_Classified/libgcj-common_6.4-3ubuntu1_all.deb |
Basically the process is opening and installing the .deb files - preferably on gdebi - in the order below. It might be interesting to open pdftk first on gdebi just to see the “impossible dependency” warning. We’re basically installing the dependencies from an older repository, so it’ll run like it did in 17.10. The order is:
After that you might want to check the status of pdftk at the software center - it might say it is not installed; install there or maybe just let it be.
Go to the terminal and check pdftk:
1 | pdftk |
1 | http://mirrors.kernel.org/ubuntu/pool/main/g/gcc-defaults/libgcj-common_6.4-3ubuntu1_all.deb |
Collate scanned pages
1 | pdftk A=even.pdf B=odd.pdf shuffle A B output collated.pdf |
or if odd.pdf is in reverse order:
1 | pdftk A=even.pdf B=odd.pdf shuffle A Bend-1 output collated.pdf |
Decrypt a PDF
1 | pdftk secured.pdf input_pw foopass output unsecured.pdf |
Encrypt a PDF using 128-bit strength (the default), withhold all permissions (the default)
1 | pdftk 1.pdf output 1.128.pdf owner_pw foopass |
Same as above, except password baz must also be used to open output PDF
1 | pdftk 1.pdf output 1.128.pdf owner_pw foo user_pw baz |
Same as above, except printing is allowed (once the PDF is open)
1 | pdftk 1.pdf output 1.128.pdf owner_pw foo user_pw baz allow printing |
Join in1.pdf and in2.pdf into a new PDF, out1.pdf
1 | pdftk in1.pdf in2.pdf cat output out1.pdf |
or (using handles):
1 | pdftk A=in1.pdf B=in2.pdf cat A B output out1.pdf |
or (using wildcards):
1 | pdftk *.pdf cat output combined.pdf |
Remove page 13 from in1.pdf to create out1.pdf
1 | pdftk in.pdf cat 1-12 14-end output out1.pdf |
or:
1 | pdftk A=in1.pdf cat A1-12 A14-end output out1.pdf |
When using the Windows command-prompt, it helps to use drag-and-drop from the file manager: drag the input PDF file from the file manager onto the command-prompt, and its full pathname will appear at the prompt.
Apply 40-bit encryption to output, revoking all permissions (the default). Set the owner PW to foopass.
1 | pdftk 1.pdf 2.pdf cat output 3.pdf encrypt_40bit owner_pw foopass |
Join two files, one of which requires the password foopass. The output is not encrypted.
1 | pdftk A=secured.pdf 2.pdf input_pw A=foopass cat output 3.pdf |
Uncompress PDF page streams for editing the PDF in a text editor (e.g., vim, emacs)
1 | pdftk doc.pdf output doc.unc.pdf uncompress |
Repair a PDF’s corrupted XREF table and stream lengths, if possible
1 | pdftk broken.pdf output fixed.pdf |
Burst a single PDF document into pages and dump its data to doc_data.txt
1 | pdftk in.pdf burst |
Burst a single PDF document into encrypted pages. Allow low-quality printing
1 | pdftk in.pdf burst owner_pw foopass allow DegradedPrinting |
Write a report on PDF document metadata and bookmarks to report.txt
1 | pdftk in.pdf dump_data output report.txt |
Rotate the first PDF page to 90 degrees clockwise
1 | pdftk in.pdf cat 1east 2-end output out.pdf |
Rotate an entire PDF document to 180 degrees
1 | pdftk in.pdf cat 1-endsouth output out.pdf |
Article Author: Sid Steward
Pdftk is a command-line program, so you should use your computer terminal or command prompt when first testing these examples.
pdftk or related: how to make a bookmark for every inserted PDF?
linux - Merge PDF’s with PDFTK with Bookmarks? - Stack Overflow
pdftk
usage1 | 合并PDF: |
1 | cd /media/ht/ht_5T_9/YouTubes/Book_Reading/深夜读书/1 |
1 | /0/Documents/Study/COVID-19 |
1 | setsid okular /media/ht/ht_5T/Work/Projects/Other_Projects/Coronavirus_Project/Ref/Vaccine/mRNA_vaccines-a_new_era_in_vaccinology.pdf |
tag:
缺失模块。
1、请确保node版本大于6.2
2、在博客根目录(注意不是yilia根目录)执行以下命令:
npm i hexo-generator-json-content --save
3、在根目录_config.yml里添加配置:
jsonContent: meta: false pages: false posts: title: true date: true path: true text: false raw: false content: false slug: false updated: false comments: false link: false permalink: false excerpt: false categories: false tags: true