There was a bit of a scare when the Android L Preview build came out and was not rootable by simply flashing the SuperSU zip in recovery. As it turns out there were no measures taken to prevent the root script you just have to redirect the installation pack to get it working again. You won't have to flash back to stock now that root is working however not every root app will work with root on Android L since all the apps have not been updated to work with root on Android L. If you can follow directions the root method is pretty straight forward. You will need the latest version of your favorite recovery, either cwm or twrp, for the Nexus 5 or Nexus 7 2013, you need the modified SuperSU-v2.00-Android-L.zip, you will need the modified boot.img for your device (Nexus5 boot.img Nexus 7 2013 boot.img), you will need adb and fastboot setup on your PC, usb debugging enabled on your phone, device charged up, and a good backup just incase something goes wrong. Boot your device into fastboot mode, Install the custom recovery via adb "fastboot flash recovery.img", reboot the device, place both the modified supersu and boot.img on your device (you could just download them straight to the phone), reboot into recovery, install the modified supersu first then install the boot.img. Once you are finished your device will be rooted.