Skip to content

Instantly share code, notes, and snippets.

@erictrn
erictrn / nvmCommands.js
Created April 2, 2024 09:11 — forked from chranderson/nvmCommands.js
Useful NVM commands
// check version
node -v || node --version
// list locally installed versions of node
nvm ls
// list remove available versions of node
nvm ls-remote
// install specific version of node
@erictrn
erictrn / countries_codes_and_coordinates.csv
Created May 25, 2022 02:40 — forked from tadast/countries_codes_and_coordinates.csv
Countries with their (ISO 3166-1) Alpha-2 code, Alpha-3 code, UN M49, average latitude and longitude coordinates
Country Alpha-2 code Alpha-3 code Numeric code Latitude (average) Longitude (average)
Afghanistan AF AFG 4 33 65
Albania AL ALB 8 41 20
Algeria DZ DZA 12 28 3
American Samoa AS ASM 16 -14.3333 -170
Andorra AD AND 20 42.5 1.6
Angola AO AGO 24 -12.5 18.5
Anguilla AI AIA 660 18.25 -63.1667
Antarctica AQ ATA 10 -90 0
Antigua and Barbuda AG ATG 28 17.05 -61.8
@erictrn
erictrn / observer.php
Created May 7, 2018 03:55 — forked from shebin512/observer.php
Magento get current full Action controller name in Observer
<?php
/*
* Get full Action controller name in Observer
*/
$request = Mage::app()->getRequest();
$module = $request->getControllerModule();
$module_controller = $request->getControllerName();
$module_controller_action = $request->getActionName();
$fullActionName = $module."_".$module_controller."_".$module_controller_action;