Skip to content

Instantly share code, notes, and snippets.

@mariafromkorea
Last active February 13, 2019 17:07
Show Gist options
  • Select an option

  • Save mariafromkorea/b3518308763f6b991ac4 to your computer and use it in GitHub Desktop.

Select an option

Save mariafromkorea/b3518308763f6b991ac4 to your computer and use it in GitHub Desktop.
Internal DevOps and Process

#Create New Solr 5 Core

  1. cd in the site root NOT the solr root
  2. run: solr create_core -c wvr -d ./sites/all/modules/contrib/search_api_solr/solr-conf/5.x
  3. swap out the moniker

#Optimize Local Images

  1. cd into theme directory
  2. Run:
    • find images/ -iname *.jpg -exec jpegoptim -p -m70 --strip-all {} ;
    • find . -name *.png | xargs optipng -nc -nb -o7 -full

#Sync Production to Dev Site

  1. Merge Dev <= Master
  2. In jenkins Room run:
  • !build rc_bot_sync MONIKER=mvv

#Update Permissions (for settings.php) sudo chmod u+w ~/filepath

#Add bt_optimize

  1. git clone bt_optimize
  2. manually delete .git from module directory
  3. git rm --cached
  4. git add, git commit

#Add Public Key cat ~/.ssh/id_rsa.pub | ssh cncdev@cnc.dev.rescmshost.com "mkdir ~/.ssh; cat >> ~/.ssh/authorized_keys"

#Find/Update PHP files ####2 PHP Files

  1. Mamp File > Edit Template
  2. Run : php -i | grep ini
  3. Then vim the Loading Configuration File path provided

#Poach updates from another site ###(Using rezFusion base in this example) Start by getting a local copy of this other site

  • git add remote [remote-name] [repo]
  • git fetch [remote-name] [branch]
    • (Example: git fetch vrw dev)

Diff new site against yours, you can diff files or entire directories)

  • git difftool [remote-name]/[remote-branch] [path-to-file-or-directory]
    • (Example: git difftool vrw/7.x-1.x ./sites/all/modules/vrweb)

Use arrows in kaledescope (or your diff tool) to grab changes

  • In split window, the remote branch is on the left and your local is on the right
  • Use page-down arrow to jump to each block of changes
  • Use page-right arrow if you want to add the changes to your local.
  • The updates on the remote will copy over to your local on the left side of the screen.

Now Use your normal git commands to add/commit/push your changes.

#Delete .info Files

  • cd into node_modules run: $ find . -iname '.info' -type f
  • if it returns something, run:
  • $ find . -iname '*.info' -type f | xargs rm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment