dropbox 怎么使用
I wrote my PhD thesis in LaTeX, and stored all of the files in my Dropbox folder. Dropbox stores previous versions of your files – for up to 30 days if you are on their free plan. Towards the end of my PhD, I realised that I could write a fairly simple Python script that would grab all of these previous versions, which I could then use to do some interesting analyses. So – over a year after my thesis was submitted, I’ve finally got around to looking at the data.
我用LaTeX撰写了博士学位论文 ,并将所有文件存储在我的Dropbox文件夹中。 Dropbox可以存储文件的早期版本-如果您使用免费计划,则最多可以存储30天。 在我博士毕业时,我意识到我可以编写一个相当简单的Python脚本,该脚本可以捕获所有这些以前的版本,然后可以用来进行一些有趣的分析。 因此,在论文提交一年后,我终于可以开始研究数据了。
I should point out here that this data comes from a sample size of one – and so if you’re writing a PhD thesis then don’t compare your speed/volume/length/whatever to me! So, with that disclaimer, on to how I did it, and what I found…
我在这里需要指出的是,这些数据来自一个样本大小的样本,因此,如果您正在写博士学位论文,那么请不要对我的速度/体积/长度/任何东西进行比较! 因此,有了该免责声明,我将了解如何实现以及发现的内容...
获取数据 (Getting the data)
I wrote a nice simple class in Python to grab all previous versions of a file from Dropbox. It’s available in the DropboxBasedWordCount repo on Github – and can be used entirely independently from the LaTeX analysis that I did. It is really easy to use, just grab the DropboxDownloader.py file, install the Dropbox library (pip install Dropbox) and run something like this:
我用Python编写了一个很好的简单类,以从Dropbox获取文件的所有先前版本。 它可以在Github上的DropboxBasedWordCount存储库中使用-可以完全独立于我所做的LaTeX分析使用。 它真的很容易使用,只需抓取DropboxDownloader.py文件,安装Dropbox库( pip install Dropbox ),然后运行以下命令:
from DropboxDownloader import DropboxDownloader
# Initialise the object and give it the folder to store its downloads in
d = DropboxDownloader('/Users/robin/ThesisFilesDropboxLog')
# Download all available previous versions
d.download_history_