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
| Example URL - http://xandeadx.ru/blog/drupal/946 | |
| --- | |
| $ composer require drush/drush | |
| --- | |
| $link = \Drupal\Core\Link::createFromRoute('My link', 'entity.node.canonical', ['node' => 123]); | |
| // По пути |
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
| # One liner | |
| wget --recursive --page-requisites --adjust-extension --span-hosts --convert-links --restrict-file-names=windows --domains yoursite.com --no-parent yoursite.com | |
| # Explained | |
| wget \ | |
| --recursive \ # Download the whole site. | |
| --page-requisites \ # Get all assets/elements (CSS/JS/images). | |
| --adjust-extension \ # Save files with .html on the end. | |
| --span-hosts \ # Include necessary assets from offsite as well. | |
| --convert-links \ # Update links to still work in the static version. |
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
| <?php | |
| /** | |
| * @file | |
| * Contains \Drupal\example_module\Controller\ExampleModuleController. | |
| */ | |
| // THIS FILE BELONGS AT /example_module/src/Controller/ExampleModuleController.php | |
| namespace Drupal\example_module\Controller; |
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
| # Source : http://thezinx.com/2013/10/29/create-bootable-dmg-iso-mavericks-app.html | |
| # Mount the installer image | |
| hdiutil attach /Applications/Install\ OS\ X\ Mavericks.app/Contents/SharedSupport/InstallESD.dmg -noverify -nobrowse -mountpoint /Volumes/install_app | |
| # Convert the boot image to a sparse bundle | |
| hdiutil convert /Volumes/install_app/BaseSystem.dmg -format UDSP -o /tmp/Mavericks | |
| # Increase the sparse bundle capacity to accommodate the packages | |
| hdiutil resize -size 8g /tmp/Mavericks.sparseimage |
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
| # Install MacTex: http://mirror.ctan.org/systems/mac/mactex/mactex-basic.pkg | |
| $ sudo chown -R `whoami` /usr/local/texlive | |
| $ tlmgr update --self | |
| $ tlmgr install ucs | |
| $ tlmgr install etoolbox | |
| # Install pandoc view homebrew |