Zurb Foundaion CLI not recognizing Zurb Stack on basic theme - zurb-foundation

I am new to Foundation and I am having issues installing blocks through the Foundation CLI. The install doesn't seem to notice the stack and keeps downloading the block as a zip
C:\Users\user\site>foundation blocks install sticky-topbar
You don't appear to be in a ZURB stack project, so we can't automatically install building blocks
? Do you want to download as a zip file? No
C:\Users\user\site>dir
Volume in drive C is OS
Volume Serial Number is CABF-C5A0
Directory of C:\Users\user\site
17/06/2019 12:17 <DIR> .
17/06/2019 12:17 <DIR> ..
17/06/2019 12:16 63 .gitignore
17/06/2019 12:16 71 CHANGELOG.md
17/06/2019 12:17 <DIR> css
17/06/2019 12:16 <DIR> etc
17/06/2019 12:16 974 gulpfile.js
17/06/2019 12:16 7,783 index.html
17/06/2019 12:16 <DIR> js
17/06/2019 12:16 <DIR> node_modules
17/06/2019 12:16 256,677 package-lock.json
17/06/2019 12:16 910 package.json
17/06/2019 12:16 1,378 README.md
17/06/2019 12:16 <DIR> scss
17/06/2019 12:16 171,452 yarn.lock
8 File(s) 439,308 bytes
7 Dir(s) 320,466,063,360 bytes free
C:\Users\user\site>
How can I correct the problem.
I have all dependencies installed and upgraded to the latest versions, including node.js
I am running Windows 10 pro

The foundation new is giving the error
Hence I reinstalled the project with the following and now Foundation CLI version 2.2.5 is recognizing the stack and installing blocks
foundation new --framework sites --template zurb

Related

How to install livewire-devtools under Chrome?

In the console of my Livewire/livewire 2 / laravel 7 app I got error :
login?email=admin%40mail.com&password=111111:60 Uncaught TypeError: window.livewire.devTools is not a function
at login?email=admin%40mail.com&password=111111:60
(anonymous) # login?email=admin%40mail.com&password=111111:60
livewire-turbolinks.js:31 Uncaught TypeError: Livewire.hook is not a function
I found this https://reposhub.com/javascript/misc/beyondcode-livewire-devtools.html page and tried to follow it
I uploaded and unpacked chrome.zip, which contains
serge#AtHome:~/chrome$ ls -la
total 48
drwxrwxr-x 5 serge serge 4096 Nov 24 18:23 .
drwxr-xr-x 40 serge serge 4096 Nov 24 18:22 ..
drwxrwxr-x 2 serge serge 4096 Aug 30 23:47 build
-rw-r--r-- 1 serge serge 78 Aug 30 23:36 devtools-background.html
-rw-r--r-- 1 serge serge 383 Aug 30 22:09 devtools.html
-rw-r--r-- 1 serge serge 6148 Sep 1 10:28 .DS_Store
drwxrwxr-x 2 serge serge 4096 Sep 1 15:08 icons
-rw-r--r-- 1 serge serge 1175 Sep 3 23:34 manifest.json
-rw-rw-r-- 1 serge serge 27 Nov 24 18:23 package-lock.json
drwxrwxr-x 2 serge serge 4096 Aug 30 23:36 popups
-rw-r--r-- 1 serge serge 162 Sep 1 18:10 .web-extension-id
But trying to install it I got errors:
serge#AtHome:~/chrome$ npm install
npm WARN saveError ENOENT: no such file or directory, open '/home/serge/chrome/package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open '/home/serge/chrome/package.json'
npm WARN chrome No description
npm WARN chrome No repository field.
npm WARN chrome No README data
npm WARN chrome No license field.
up to date in 0.523s
found 0 vulnerabilities
serge#AtHome:~/chrome$ npm run build
npm ERR! code ENOENT
npm ERR! syscall open
npm ERR! path /home/serge/chrome/package.json
npm ERR! errno -2
npm ERR! enoent ENOENT: no such file or directory, open '/home/serge/chrome/package.json'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! A complete log of this run can be found in:
npm ERR! /home/serge/.npm/_logs/2020-11-24T16_23_38_605Z-debug.log
I do not see file package.json, but have file package-lock.json, which contains :
{
"lockfileVersion": 1
}
What have I to do to install it under my Google Chrome Version 85.0.4183.121 (Official Build) (64-bit) ?
MODIFIED BLOCK :
I loaded and installed package from https://github.com/beyondcode/livewire-devtools
and selected in under chrome://extensions/
but I see erros buttons red: https://prnt.sc/vqgk51
and clicking on it I see error:
Error in event handler: ReferenceError: suffix is not defined
Context
_generated_background_page.html
Stack Trace
build/background.js:1 (anonymous function)
!function(e){var n={};function o(t){if(n[t])return n[t].exports;var s=n[t]={i:t,l:!1,exports:{}};return e[t].call(s.exports,s,s.exports,o),s.l=!0,s.exports}o.m=e,o.c=n,o.d=function(e,n,t){o.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:t})},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,"a",n),n},o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.p="",o(o.s=659)}({659:function(e,n){const o={};let t;chrome.runtime.onConnect.addListener(e=>{let n,t;!function(e){return+e+""===e}(e.name)?(n=e.sender.tab.id,t="backend"):(n=e.name,t="devtools",function(e){chrome.tabs.executeScript(e,{file:"/build/proxy.js"},function(n){n?console.log("injected proxy to tab "+e):o[e].devtools.postMessage("proxy-fail")})}(+e.name)),o[n]||(o[n]={devtools:null,backend:null}),o[n][t]=e,o[n].devtools&&o[n].backend&&function(e,n,t){function s(n){if("log"===n.event)return console.log("tab "+e,n.payload);console.log("devtools -> backend",n),t.postMessage(n)}function c(o){if("log"===o.event)return console.log("tab "+e,o.payload);console.log("backend -> devtools",o),n.postMessage(o)}function r(){console.log("tab "+e+" disconnected."),n.onMessage.removeListener(s),t.onMessage.removeListener(c),n.disconnect(),t.disconnect(),o[e]=null}n.onMessage.addListener(s),t.onMessage.addListener(c),n.onDisconnect.addListener(r),t.onDisconnect.addListener(r),console.log("tab "+e+" connected.")}(n,o[n].devtools,o[n].backend)}),chrome.runtime.onMessage.addListener((e,n)=>{n.tab&&e.livewireDetected&&(chrome.browserAction.setIcon({tabId:n.tab.id,path:{16:"icons/1.png",48:"icons/48.png",128:"icons/128.png"}}),chrome.browserAction.setPopup({tabId:n.tab.id,popup:e.devtoolsEnabled?`popups/enabled${suffix}.html`:`popups/disabled${suffix}.html`}))}),chrome.tabs.onActivated.addListener(({tabId:e})=>{t=e}),chrome.contextMenus.onClicked.addListener((e,n)=>{chrome.runtime.sendMessage({vueContextMenu:{id:e.menuItemId}})})}});
I reopened Chrome and reloaded Kubutu.
What can be the issue and how to fix it ?
MODIFIED:
Looking at branch https://github.com/beyondcode/livewire-devtools/issues/6
I found some hints how it can be fixed:
In file package.json I added
"devDependencies": {
"eslint": "^7.9.0"
},
eslint line and run
npm install
npm run watch-poll
with success
In my project I found 3 files :
/vendor/livewire/livewire/dist/manifest.json
/public/mix-manifest.json
/public/vendor/livewire/manifest.json
but all these 3 files are autogenerated I do not know which file have I to edit as I read :
{
...
"permissions": [
"http://*/*",
"https://*/*",
+ "contextMenus"
],
...
}
contextMenus is missed in manifest.json
?
Thanks!

docker-compose on windows directory sync

Running the django tutorial for docker compose, but the command to init the django project is not working as expected.
$ docker-compose run web django-admin.py startproject composeexample .
[31mERROR[0m: Interactive mode is not yet supported on Windows.
Please pass the -d flag when using `docker-compose run`.
In windows "interactive" mode is not supported so I modified the command to run in "detached" mode.
$ docker-compose run -d web django-admin.py startproject composeexample .
Creating network "djangotest_default" with the default driver
...
Successfully built 0fb90648c1d8
[33mWARNING[0m: Image for service web was built because it did not already exist. To rebuild this image you must use `docker-compose build` or `docker-compose up --build`.
djangotest_web_run_1
This seems to create the boxes.. but my current directory shows no new files (from the django-admin command).
$ ls
docker-compose.yml Dockerfile requirements.txt
How do I get the container output to sync with the current working directory as expected?
The fix was to uninstall Windows 10 and install a *nix system. The files then appear as per the tutorial.
~/docker/django-test $ ll
total 60
drwxr-xr-x 4096 Sep 24 00:47 ./
drwxr-xr-x 4096 Sep 24 00:40 ../
drwxr-xr-x 4096 Sep 24 00:47 composeexample/
-rw-r--r-- 209 Sep 24 00:41 docker-compose.yml
-rw-r--r-- 146 Sep 24 00:41 Dockerfile
-rwxr-xr-x 812 Sep 24 00:47 manage.py*
-rw-r--r-- 16 Sep 24 00:41 requirements.txt

How do I build and install a Puppet module locally from source?

I found a puppet module whose authors just added a bunch of modifications that I would otherwise have to make myself, manually.
This literally occurred 20 hours ago.
I have downloaded the master branch to a zip file, extracted it to my modules folder, and run puppet module build --verbose /etc/puppet/modules/arioch-redis, to no avail.
I understand that this is definitely not normal behavior, but I feel this question deserves some attention.
There is definitely a use case for using a module from source, especially in projects that move quickly, or rely on quick feedback.
I have done some research on this, and please feel free to ask, "have you looked into X" questions in the comments.
For instance, I looked over https://docs.puppetlabs.com/puppet/latest/reference/modules_publishing.html#build-your-module, but it seems mainly geared toward uploading a module to the Forge, rather than installing locally from source.
Plus, my attempt fails at the "Build Your Module" section.
All three of the following seem to answer this question with "install librarian-puppet", but given that we can write our own modules, it seems silly to have to use librarian-puppet to use the source code from a publicly available git repository to use a simple module:
Changing puppet module source (I'm looking for an answer to what happens after the OP would create the private repo in that answer. )
How to install a puppet file from a local repo with puppet module install (My Excuse: I don't need to use only the puppet module install tool. I can use other puppet tools, too.)
Using puppet module straight from a cloned repo (My Excuse: Answer does not seem relevant to this question.)
Installing a puppet module from a manifest script (My Excuse: Again, the best answer, which I think is perfect for that question, is "don't use Puppet for this, find a workaround." In this case, the workaround was to have Vagrant partially use Shell Provisioning.)
If this really is a duplicate, or a summary, please say so in the comments, and maybe I can explain. Edits welcome!
Do I need to hack the metadata.json contents?
Should I clone this repository somewhere and link it into my own temporary Forge account, or something?
Summary:
How might I get the veeeeerry latest build of the module, when it's passing in Travis on its Git repository, but before the Forge makes it available?
Puppet modules downloaded from the forge are still folders, the puppet module command is just untarring them and downloading dependencies with the API.
So your approach was close, you just need to make sure the folder has the right directory name:
So for your example:
$ puppet module list
/Users/foo/.puppet/modules
├── fiddyspence-sysctl (v1.1.0)
├── puppetlabs-apt (v1.8.0)
├── puppetlabs-aws (v1.0.0)
├── puppetlabs-nodejs (v0.7.1)
└── puppetlabs-stdlib (v4.6.0)
$ cd /Users/foo/.puppet/modules
$ ll
total 0
drwxr-xr-x 15 foo staff 510 Mar 17 2015 apt
drwxr-xr-x 18 foo staff 612 Mar 26 2015 aws
drwxr-xr-x 14 foo staff 476 Jan 22 2015 nodejs
drwxr-xr-x 17 foo staff 578 Apr 15 2015 stdlib
drwxr-xr-x 12 foo staff 408 Feb 9 2015 sysctl
$ wget https://github.com/arioch/puppet-redis/archive/master.zip
--2015-12-02 11:56:24-- https://github.com/arioch/puppet-redis/archive/master.zip
Resolving github.com... 192.30.252.130
Connecting to github.com|192.30.252.130|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://codeload.github.com/arioch/puppet-redis/zip/master [following]
--2015-12-02 11:56:24-- https://codeload.github.com/arioch/puppet-redis/zip/master
Resolving codeload.github.com... 192.30.252.144
Connecting to codeload.github.com|192.30.252.144|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 29509 (29K) [application/zip]
Saving to: 'master.zip'
master.zip 100%[==================================================>] 28.82K --.-KB/s in 0.1s
2015-12-02 11:56:25 (257 KB/s) - 'master.zip' saved [29509/29509]
$ unzip master.zip
Archive: master.zip
4fb33b960a09bfb459eff20ee112bfc9e0a1c096
creating: puppet-redis-master/
inflating: puppet-redis-master/.fixtures.yml
inflating: puppet-redis-master/.gitignore
extracting: puppet-redis-master/.puppet-lint.rc
inflating: puppet-redis-master/.travis.yml
inflating: puppet-redis-master/Gemfile
inflating: puppet-redis-master/LICENSE
inflating: puppet-redis-master/README.md
inflating: puppet-redis-master/Rakefile
creating: puppet-redis-master/manifests/
inflating: puppet-redis-master/manifests/config.pp
inflating: puppet-redis-master/manifests/init.pp
inflating: puppet-redis-master/manifests/install.pp
inflating: puppet-redis-master/manifests/params.pp
inflating: puppet-redis-master/manifests/preinstall.pp
inflating: puppet-redis-master/manifests/sentinel.pp
inflating: puppet-redis-master/manifests/service.pp
inflating: puppet-redis-master/metadata.json
creating: puppet-redis-master/spec/
creating: puppet-redis-master/spec/classes/
inflating: puppet-redis-master/spec/classes/redis_sentinel_spec.rb
inflating: puppet-redis-master/spec/classes/redis_spec.rb
extracting: puppet-redis-master/spec/spec.opts
inflating: puppet-redis-master/spec/spec_helper.rb
creating: puppet-redis-master/templates/
inflating: puppet-redis-master/templates/redis-sentinel.conf.erb
inflating: puppet-redis-master/templates/redis-sentinel.init.erb
inflating: puppet-redis-master/templates/redis.conf.erb
$ mv puppet-redis-master/ redis
$ ll
total 64
drwxr-xr-x 15 foo staff 510 Mar 17 2015 apt
drwxr-xr-x 18 foo staff 612 Mar 26 2015 aws
-rw-r--r-- 1 foo staff 29509 Dec 2 11:56 master.zip
drwxr-xr-x 14 foo staff 476 Jan 22 2015 nodejs
drwxr-xr-x 14 foo staff 476 Nov 30 15:10 redis
drwxr-xr-x 17 foo staff 578 Apr 15 2015 stdlib
drwxr-xr-x 12 foo staff 408 Feb 9 2015 sysctl
You'll notice it complains about missing dependancies.
$ puppet module list
Warning: Module 'puppetlabs-apt' (v1.8.0) fails to meet some dependencies:
'arioch-redis' (v1.1.3) requires 'puppetlabs-apt' (>= 2.0.1 <3.0.0)
Warning: Missing dependency 'stahnma-epel':
'arioch-redis' (v1.1.3) requires 'stahnma-epel' (>= 1.0.2 <2.0.0)
/Users/foo/.puppet/modules
├── arioch-redis (v1.1.3)
├── fiddyspence-sysctl (v1.1.0)
├── puppetlabs-apt (v1.8.0) invalid
├── puppetlabs-aws (v1.0.0)
├── puppetlabs-nodejs (v0.7.1)
└── puppetlabs-stdlib (v4.6.0)
As far as I'm aware: There's no way to resolve dependencies from a local module using Puppet's module command.
That's where librarian-puppet is comes in:
$ cd redis/
$ librarian-puppet install --path ../. --verbose
[Librarian] Ruby Version: 2.1.2
[Librarian] Ruby Platform: x86_64-darwin14.0
[Librarian] Rubygems Version: 2.4.8
[Librarian] Librarian Version: 0.6.3
[Librarian] Librarian Adapter: puppet
[Librarian] Librarian Adapter Version: 2.2.1
[Librarian] Project: /Users/foo/.puppet/modules/redis
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /opt/boxen/homebrew/bin/git
[Librarian] Git Version: 2.4.3
[Librarian] Git Environment Variables:
[Librarian] GIT_PS1_SHOWDIRTYSTATE=true
[Librarian] GIT_PS1_SHOWSTASHSTATE=true
[Librarian] GIT_PS1_SHOWUNTRACKEDFILES=true
[Librarian] GIT_PS1_SHOWUPSTREAM=auto
[Librarian] Pre-Cached Sources:
[Librarian] [:forge, "https://forgeapi.puppetlabs.com", {}]
[Librarian] Specfile /Users/foo/.puppet/modules/redis/Puppetfile not found, using defaults
[Librarian] Post-Cached Sources:
[Librarian] [:forge, "https://forgeapi.puppetlabs.com", {}]
[Librarian] The specfile is unchanged: nothing to do.
[Librarian] Install: dependencies resolved
[Librarian] Installing puppetlabs-stdlib/4.9.0 <https://forgeapi.puppetlabs.com>
[Librarian] Installing puppetlabs-apt/2.2.0 <https://forgeapi.puppetlabs.com>
[Librarian] Installing stahnma-epel/1.2.0 <https://forgeapi.puppetlabs.com>
$ puppet module list
/Users/petersouter/.puppet/modules
├── arioch-redis (v1.1.3)
├── fiddyspence-sysctl (v1.1.0)
├── puppetlabs-apt (v2.2.0)
├── puppetlabs-aws (v1.0.0)
├── puppetlabs-nodejs (v0.7.1)
├── puppetlabs-stdlib (v4.9.0)
└── stahnma-epel (v1.2.0)
If you don't want to use puppet-librarian, you could also just update those modules manually:
$ puppet module install puppetlabs-apt -v 2.0.1 --force
Notice: Preparing to install into /Users/petersouter/.puppet/modules ...
Notice: Downloading from https://forgeapi.puppetlabs.com ...
Notice: Installing -- do not interrupt ...
/Users/foo/.puppet/modules
└── puppetlabs-apt (v2.0.1)
$ puppet module install stahnma-epel -v 1.2.0 --force
Notice: Preparing to install into /Users/petersouter/.puppet/modules ...
Notice: Downloading from https://forgeapi.puppetlabs.com ...
Notice: Installing -- do not interrupt ...
/Users/foo/.puppet/modules
└── stahnma-epel (v1.2.0)

Uploading code of django to github repository in ubuntu

I have this little problem regarding to upload my existing django project to github repository.
This is my working directory and here my django code stays.
mjrulesamrat#mjrulesamrat-Lenovo-G570:~/django_mj/django_test$ ls -l
total 56
drwxrwxr-x 4 mjrulesamrat mjrulesamrat 4096 Aug 27 05:31 article
-rw-r--r-- 1 mjrulesamrat mjrulesamrat 34816 Aug 26 21:42 db.sqlite3
drwxrwxr-x 2 mjrulesamrat mjrulesamrat 4096 Aug 27 06:35 django_test
-rwxr-xr-x 1 mjrulesamrat mjrulesamrat 254 Aug 25 18:09 manage.py
-rw-rw-r-- 1 mjrulesamrat mjrulesamrat 0 Aug 27 06:46 README.md
drwxrwxr-x 4 mjrulesamrat mjrulesamrat 4096 Aug 27 05:35 static
drwxrwxr-x 2 mjrulesamrat mjrulesamrat 4096 Aug 27 05:33 templates
Now when i try to add or commit it says following msg.
mjrulesamrat#mjrulesamrat-Lenovo-G570:~/django_mj/django_test$ git add .
mjrulesamrat#mjrulesamrat-Lenovo-G570:~/django_mj/django_test$ git status
On branch master
nothing to commit, working directory clean
mjrulesamrat#mjrulesamrat-Lenovo-G570:~/django_mj/django_test$ git commit -m "app_commit_no_4"
On branch master
nothing to commit, working directory clean
mjrulesamrat#mjrulesamrat-Lenovo-G570:~/django_mj/django_test$
Please help me upload code to my repository.
to upload my code to github repository, I usually create my project on github first.
clone my project to my PC with git clone https://github.com/myusername/myproject.git
copy - paste to my code to cloned project.
run git add .
run git commit -am 'this is msg'
run git push origin master
First of all I have made changes on the remote repository.
That's why it was giving me error.
So, first i have to pull the changes from the remote repository and then i have to push the changes.
These are the commands that I followed.
I learned from my sir later.
git pull remote_repo
git add .
git status
git commit -m "message"
git push -u origin master
This works good till date.

fossil v1.24 fails on linux with 'no such file'

If I download fossil v1.23 to my linux server, everything goes fine.
root#x:/home/james/test# unzip fossil-linux-x86-20120808112557.zip
Archive: fossil-linux-x86-20120808112557 (1).zip
inflating: fossil
root#x:/home/james/test# mv fossil fossil_1_23
root#x:/home/james/test# chmod 777 fossil_1_23
root#x:/home/james/test# ./fossil_1_23 help
Usage: ./fossil_1_23 help COMMAND
Common COMMANDs: (use "./fossil_1_23 help --all" for a complete list)
add clean gdiff mv rm timeline
addremove clone help open settings ui
all commit import pull sqlite3 undo
annotate diff info push stash update
bisect export init rebuild status version
branch extras ls remote-url sync
changes finfo merge revert tag
This is fossil version 1.23 [957b17af58] 2012-08-08 11:25:57 UTC
But 1.24 fails, with 'No such file' even though a ls command shows the file is present, like this:
root#x:/home/james/test# unzip fossil-linux-x86-20121022124804.zip
Archive: fossil-linux-x86-20121022124804.zip
inflating: fossil
oot#x:/home/james/test# mv fossil fossil_1_24
root#x:/home/james/test# chmod 777 fossil_1_24
root#x:/home/james/test# ls -l
total 3620
-rw-r--r-- 1 root root 528859 Oct 24 10:04 fossil-linux-x86-20120808112557.zip
-rw-r--r-- 1 root root 670298 Oct 24 10:04 fossil-linux-x86-20121022124804.zip
-rwxrwxrwx 1 root root 1061584 Aug 11 10:30 fossil_1_23
-rwxrwxrwx 1 root root 1418656 Oct 22 09:16 fossil_1_24
root#x:/home/james/test# ./fossil_1_24 help
-bash: ./fossil_1_24: No such file or directory
Richard Hipp rebuilt the 1.24 linux binary. The new version works fine.