$ cd /usr/ports/net-p2p/transmission-daemon
$ sudo make install
$ sudo mkdir /srv/torrents/{autoload,data}
$ sudo chown -R transmission:transmission /srv/torrents/
$ sudo chmod -R go+w /srv/torrents/
$ sudo vim /etc/rc.conf
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
| %%%------------------------------------------------------------------- | |
| %%% @author Ahmad Baitalmal | |
| %%% @copyright (C) 2017, Ahmad Baitalmal | |
| %%% Permission is hereby granted, free of charge, to any person obtaining | |
| %%% a copy of this software and associated documentation files | |
| %%% (the “Software”), to deal in the Software without restriction, | |
| %%% including without limitation the rights to use, copy, modify, merge, | |
| %%% publish, distribute, sublicense, and/or sell copies of the Software, | |
| %%% and to permit persons to whom the Software is furnished to do so, | |
| %%% subject to the following conditions: |
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
| ############################## | |
| # _ | |
| # | |_ _ __ ___ _ ___ __ | |
| # | __| '_ ` _ \| | | \ \/ / | |
| # | |_| | | | | | |_| |> < | |
| # \__|_| |_| |_|\__,_/_/\_\ | |
| # | |
| ############################# | |
| # | |
| # COPY AND PASTE |
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
| # Add sinon.js gem to your `group :development, :test` | |
| gem 'sinon-rails' | |
| # Add code to stub javascript time in your application.haml (.erb) layout file, at the same time you are using Timecop.travel | |
| - if defined?(Timecop) && Timecop.top_stack_item | |
| = javascript_include_tag "sinon" | |
| - unix_millis = (Time.now.to_f * 1000.0).to_i | |
| :javascript | |
| sinon.useFakeTimers(#{unix_millis}); |
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
| # Add gem | |
| https://github.com/toy/image_optim | |
| # For production/demo install instructions look in gem readme | |
| ### UBUNTU 12.04 image_optim requirments: | |
| > sudo add-apt-repository ppa:danmbox/ppa | |
| > sudo apt-get update | |
| > sudo apt-get install -y advancecomp gifsicle jhead jpegoptim libjpeg-progs optipng pngcrush pngquant | |
| # download pngout from http://www.jonof.id.au/kenutils |
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
| =Navigating= | |
| visit('/projects') | |
| visit(post_comments_path(post)) | |
| =Clicking links and buttons= | |
| click_link('id-of-link') | |
| click_link('Link Text') | |
| click_button('Save') | |
| click('Link Text') # Click either a link or a button | |
| click('Button Value') |