Questions tagged [guard]

Guard is a command line tool to easily handle events on file system modifications.

Guard is a command line tool to easily handle events on file system modifications (FSEvent / Inotify / Polling support).

884 questions
-1
votes
1 answer

guard not recognizing file changes on windows share mounted in Ubuntu using samba

I have my rails application file on my windows Host OS where I like to edit it with sublime text 2. I'm running Ubuntu 14.04 in a VirtualBox VM with a host-only network adapter. I use the Ubuntu OS guest for my development environment other than…
-1
votes
1 answer

function that uses guards and a where clause then I want to change it using recursion

I am trying implement a function that can check scores and a list of all the scores in the class and then tells you by producing a string what do you get are you above the average or not. It should be as the following expression : scoreChecker 45…
wadbarca
  • 59
  • 1
  • 6
-1
votes
1 answer

Trying to Install Way Guard Laravel

I am trying to install Way/Guard-laravel and I get a huge error in the terminal. I know absolutely nothing about ruby, and Gems, nor do I want to risk my computer trying to debug this problem. Here is the error Joels-iMac:work2 joelcox$ art…
user3095721
  • 51
  • 1
  • 5
-1
votes
1 answer

Speeding up notifications for autotest on Ubuntu

I've figured out how to run guard on my ubuntu desktop to use while doing Ruby on Rails development. The notifications are quite useful, but lag forever behind guard, so if I run a test, I'll wait for two minutes afterward waiting for the…
mathieu
  • 107
  • 2
  • 11
-2
votes
2 answers

How to check the logged in user in multiple guard?

I am using laravel 10. I have 2 guards. One is admin and another is manager . The Auth only authenticate the default one so in the controller construction I have set public function __construct(){ …
enamul haque
  • 1,069
  • 1
  • 10
  • 18
-2
votes
2 answers

How do I add a guard to something when there's multiple answers?

I'm completely new to any sort of programming/coding and know nothing about it and only recently started learning coding on Haskell. I am learning about guards and know that they work for Booleans (I'm only just starting to grasp what they are now…
baleil
  • 1
  • 1
-2
votes
1 answer

Which way is recommended to use guard let?

I need to check preconditions for proceeding a function in iOS/Swift. Option 1: guard let name = str["name"], let age = str["age"] else { print("name/age missing") return } Option 2: guard let name = str["name"] else { print("name…
Sazzad Hissain Khan
  • 37,929
  • 33
  • 189
  • 256
-2
votes
1 answer

Null Guard for Nested Objects With Hierarchy Path Recognition in C#

I'm trying to create a nested Guard method (or find an existing Guard library) that would throw an exception if any object in a nested hierarchy is NULL and include the name of the object hierarchy path up to and including NULL. I also want to avoid…
AlexVPerl
  • 7,652
  • 8
  • 51
  • 83
-2
votes
1 answer

Get a nil when I check url string image

I have empty url string from my image. I keep my url string image in firestore. But sometimes it happens that there is no image and I need to make a check and return an empty image. When I load my view I get an error nil. Because my variable in…
-3
votes
2 answers

How to check JSON can be converted to dictionary in Swift?

Tried this, but get error: var d = (try JSONSerialization.jsonObject(with: data, options: JSONSerialization.ReadingOptions.mutableContainers)) as [String: String] guard let d2 = d else { return }
János
  • 32,867
  • 38
  • 193
  • 353
-3
votes
1 answer

Swift do-return with guard condition?

I'm trying to translate some Swift code to C#. I read the docs, but am not able to grasp what this code block does. I'm not able to run the code, so that makes it even harder. Please help! do { oldArray.enumerated().forEach { oldTuple in …
l33t
  • 18,692
  • 16
  • 103
  • 180
-3
votes
1 answer

Ruby on Windows: Require is not recognized as an internal or external command

I'm trying to use Guard to monitor changes in AsciiDoctor file. Here is Guardfile from official docs: require 'asciidoctor' guard 'shell' do watch(/^mydoc\.adoc$/) {|m| Asciidoctor.convert_file m[0] } end It works for me. But now, I'm…
john c. j.
  • 725
  • 5
  • 28
  • 81
-5
votes
2 answers

C++ header guard not working

I'm trying to get my includes working, but everything I try leads to errors. Even using #pragma once doesn't work. Do you know what I made wrong? main.cpp #include "utility/headers/Window.h" #include "engine/headers/Player.h" #include…
yxyx136
  • 17
  • 1
  • 8
-5
votes
2 answers

What is a c include file and guard?

You must create an include file that contains symbols for DEBUG, TRUE, FALSE, NULL. The include file must contain a guard.--> I have no Idea what is this. When I read it I just see chinese. What is an include file and how can I make it contain…
user1212697
  • 619
  • 1
  • 6
  • 7
1 2 3
58
59