{"action":"created","issue":{"url":"https://api.github.com/repos/zplug/zplug/issues/252","repository_url":"https://api.github.com/repos/zplug/zplug","labels_url":"https://api.github.com/repos/zplug/zplug/issues/252/labels{/name}","comments_url":"https://api.github.com/repos/zplug/zplug/issues/252/comments","events_url":"https://api.github.com/repos/zplug/zplug/issues/252/events","html_url":"https://github.com/zplug/zplug/issues/252","id":174733673,"number":252,"title":"lazy form local is not working in newest zplug","user":{"login":"eth3lbert","id":2889664,"avatar_url":"https://avatars.githubusercontent.com/u/2889664?v=3","gravatar_id":"","url":"https://api.github.com/users/eth3lbert","html_url":"https://github.com/eth3lbert","followers_url":"https://api.github.com/users/eth3lbert/followers","following_url":"https://api.github.com/users/eth3lbert/following{/other_user}","gists_url":"https://api.github.com/users/eth3lbert/gists{/gist_id}","starred_url":"https://api.github.com/users/eth3lbert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eth3lbert/subscriptions","organizations_url":"https://api.github.com/users/eth3lbert/orgs","repos_url":"https://api.github.com/users/eth3lbert/repos","events_url":"https://api.github.com/users/eth3lbert/events{/privacy}","received_events_url":"https://api.github.com/users/eth3lbert/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/zplug/zplug/labels/BUG","name":"BUG","color":"fc2929"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":14,"created_at":"2016-09-02T10:58:46Z","updated_at":"2016-09-14T08:27:04Z","closed_at":null,"body":"## Problem Summary\r\n\r\nI was trying to load function lazily form local in specific location with `from:local,  lazy:1, and use:\"glob_path\"`. It works at v2.1.0 but fails at v2.2.0, Zplug did not generate autoload statement like previous version.\r\n\r\n## System Information\r\n\r\n- `uname -a`\r\n\r\n    ```\r\nLinux labweb-ThinkCentre-M57e 3.19.0-59-generic #66-Ubuntu SMP Thu May 12 22:35:27 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux\r\n    ```\r\n\r\n- zsh version\r\n\r\n    ```\r\nzsh 5.0.7 (x86_64-pc-linux-gnu)\r\n    ```\r\n\r\n- zplug version/commit\r\n\r\n    ```\r\n2.2.0\r\n    ```\r\n\r\n## Minimal zshrc\r\n\r\nCreate a minimal reproducing set of configurations for this issue. Please\r\nremove all unnecessary parts!\r\nps. update to fix some typo `zim_mods=('enviroment', 'git') -> zim_mods=('environment','git')`\r\n\r\n```zsh\r\n#!/bin/zsh\r\nXDG_CONFIG_HOME=\"${XDG_CONFIG_HOME:-${HOME}/.config}\"\r\nXDG_DATA_HOME=\"${XDG_DATA_HOME:-${HOME}/.local/share}\"\r\nexport ZPLUG_HOME=\"${XDG_DATA_HOME}/zplug\"\r\nexport ZPLUG_REPOS=\"${ZPLUG_HOME}/repos\"\r\nexport ZPLUG_CACHE_FILE=\"${ZPLUG_HOME}/.cache\"\r\nif [ ! -f ${ZPLUG_HOME}/init.zsh ]; then\r\n    echo \"$fg_bold[yellow]Installing zplug...$reset_color\\n\"\r\n    mkdir -p ${ZPLUG_HOME}\r\n    git clone https://github.com/zplug/zplug ${ZPLUG_HOME}\r\n    #cd ${ZPLUG_HOME}\r\n    #git checkout 2.1.0\r\n    #cd -\r\n    source \"${ZPLUG_HOME}/init.zsh\"\r\n    echo \"$fg_bold[yellow]Done ! $reset_color\\n\"\r\nfi\r\nsource \"${ZPLUG_HOME}/init.zsh\"\r\n\r\nzplugs=()\r\n\r\nzim_mods=('environment','git')\r\n\r\nzplug \"Eriner/zim\", \\\r\n  depth:1, \\\r\n  use:\"modules/{${(j:,:)zim_mods}}/init.zsh\"\r\n\r\nzplug \"${ZPLUG_REPOS}/Eriner/zim/modules\", \\\r\n  from:local, \\\r\n  use:\"{${(j:,:)zim_mods}}/functions/*(N)\", \\\r\n  ignore:\"**/functions/example_function\", \\\r\n  lazy:1, \\\r\n  on:\"Eriner/zim\"\r\n\r\nunset zim_mods\r\n\r\nif ! zplug check --verbose; then\r\n  printf \"Install? [y/N]: \"\r\n  if read -q; then\r\n    echo; zplug install\r\n  fi\r\nfi\r\n\r\nzplug load --verbose\r\n\r\n```\r\n\r\n## Steps to Reproduce\r\n\r\n1.  Setup as above.\r\n\r\nAlthough it shows `[zplug] ERROR: sources/local is not defined` when installing, but it still source them.\r\n\r\nThe following is the generated cache by zplug at v2.2.0:\r\n```zsh\r\n#!/usr/bin/env zsh\r\n\r\n# This file was generated by zplug\r\n# *** DO NOT EDIT THIS FILE ***\r\n\r\n[[ $- =~ i ]] || exit\r\nexport ZSH=${ZSH:-/home/labweb/.local/share/zplug/repos/robbyrussell/oh-my-zsh}\r\nexport ZSH_CACHE_DIR=${ZSH_CACHE_DIR:-$ZSH/cache}/\r\n\r\nif $is_verbose; then\r\n  echo \"Static loading...\" >&2\r\nfi\r\n\r\n# Plugins\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/environment/init.zsh\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/init.zsh\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-branch-current\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-commit-lost\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git_current_branch\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-dir\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-ignore-add\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git_prompt_info\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-root\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-stash-clear-interactive\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-stash-dropped\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-stash-recover\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-submodule-move\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/git-submodule-remove\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/is-true\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/functions/parse_git_dirty\"\r\n\r\n\r\ncompinit -C -d /home/labweb/.local/share/zplug/zcompdump\r\n\r\n\r\nreturn 0\r\nEriner/zim, depth:1 use:modules/{environment,git}/init.zsh\r\n/home/labweb/.local/share/zplug/repos/Eriner/zim/modules, from:local ignore:**/functions/example_function lazy:1 on:Eriner/zim use:{environment,git}/functions/*(N)\r\n\r\n```\r\nThe following is the generated cache by zplug at v2.1.0:\r\n```zsh\r\n#!/bin/zsh\r\n\r\n# This file was generated by zplug\r\n# *** DO NOT EDIT THIS FILE ***\r\n\r\n[[ $- =~ i ]] || exit\r\nexport PATH=\"/home/labweb/.local/share/zplug/bin:$PATH\"\r\nexport ZSH=/home/labweb/.local/share/zplug/repos/robbyrussell/oh-my-zsh\r\n\r\nif $is_verbose; then\r\n  echo \"Static loading...\" >&2\r\nfi\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/environment/init.zsh\"\r\nsource \"/home/labweb/.local/share/zplug/repos/Eriner/zim/modules/git/init.zsh\"\r\ncompinit -C -d /home/labweb/.local/share/zplug/zcompdump\r\n\r\n# Lazy loading plugins\r\nautoload -Uz \"git-branch-current\"\r\nautoload -Uz \"git-commit-lost\"\r\nautoload -Uz \"git_current_branch\"\r\nautoload -Uz \"git-dir\"\r\nautoload -Uz \"git-ignore-add\"\r\nautoload -Uz \"git_prompt_info\"\r\nautoload -Uz \"git-root\"\r\nautoload -Uz \"git-stash-clear-interactive\"\r\nautoload -Uz \"git-stash-dropped\"\r\nautoload -Uz \"git-stash-recover\"\r\nautoload -Uz \"git-submodule-move\"\r\nautoload -Uz \"git-submodule-remove\"\r\nautoload -Uz \"is-true\"\r\nautoload -Uz \"parse_git_dirty\"\r\n\r\n# Hooks after load\r\n\r\n\r\nreturn 0\r\ndepth:1, name:Eriner/zim, use:modules/{environment,git}/init.zsh\r\nfrom:local, ignore:**/functions/example_function, lazy:1, name:/home/labweb/.local/share/zplug/repos/Eriner/zim/modules, on:Eriner/zim, use:{environment,git}/functions/*(N)\r\n```"},"comment":{"url":"https://api.github.com/repos/zplug/zplug/issues/comments/246941730","html_url":"https://github.com/zplug/zplug/issues/252#issuecomment-246941730","issue_url":"https://api.github.com/repos/zplug/zplug/issues/252","id":246941730,"user":{"login":"eth3lbert","id":2889664,"avatar_url":"https://avatars.githubusercontent.com/u/2889664?v=3","gravatar_id":"","url":"https://api.github.com/users/eth3lbert","html_url":"https://github.com/eth3lbert","followers_url":"https://api.github.com/users/eth3lbert/followers","following_url":"https://api.github.com/users/eth3lbert/following{/other_user}","gists_url":"https://api.github.com/users/eth3lbert/gists{/gist_id}","starred_url":"https://api.github.com/users/eth3lbert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eth3lbert/subscriptions","organizations_url":"https://api.github.com/users/eth3lbert/orgs","repos_url":"https://api.github.com/users/eth3lbert/repos","events_url":"https://api.github.com/users/eth3lbert/events{/privacy}","received_events_url":"https://api.github.com/users/eth3lbert/received_events","type":"User","site_admin":false},"created_at":"2016-09-14T08:27:04Z","updated_at":"2016-09-14T08:27:04Z","body":"@NigoroJr I just copy paste your code, but nothing change..."}}
{"actor":{"display_login":"eth3lbert"}}