Меню

Could not change to the templates directory ошибка c

0 / 0 / 0

Регистрация: 25.08.2018

Сообщений: 2

1

25.08.2018, 22:19. Показов 2255. Ответов 5


Возникает проблема при создании проекта в Dev-C++ 5.4.2 : Could not change to the Templates directory()…

__________________
Помощь в написании контрольных, курсовых и дипломных работ, диссертаций здесь



0



223 / 188 / 97

Регистрация: 15.04.2018

Сообщений: 718

25.08.2018, 23:37

2

Возможно, не хватает прав доступа к папке с временными файлами. Попробуйте запустить свой Dev-C++ от администратора, если вы на винде



0



1 / 1 / 0

Регистрация: 25.12.2016

Сообщений: 34

26.08.2018, 00:35

3

Попробуйте создать проект в отдельной папке на диске D =)



0



0 / 0 / 0

Регистрация: 25.08.2018

Сообщений: 2

26.08.2018, 11:08

 [ТС]

4

К сожалению, не помогает



0



544 / 868 / 144

Регистрация: 10.08.2015

Сообщений: 4,456

27.08.2018, 00:19

5

для начала следовало бы обновить версию Dev-C++



0



Just Do It!

3421 / 1891 / 623

Регистрация: 23.09.2014

Сообщений: 5,968

Записей в блоге: 1

27.08.2018, 00:59

6

t_ns,
да, верно, обновите свой DEV C++
на 5.11 от Bloodshed
он на два года свежее, чем ваш)
https://sourceforge.net/projec… t/download



0



I am using Dev C++ for programming, and I can create a new file, but not a project. If I try to create a project then this error occurs:

Could not change to the Templates Directory()..»

How can I fix this problem?

Michael Gaskill's user avatar

asked Mar 26, 2016 at 13:18

Shahid Mehmood's user avatar

A problem like this sometimes is solved in the easiest way by just not solving it at all. Try to update Dev-C++ and then restart it and see if that works. If it doesn’t, then uninstall it and download it directly from Blookshed.net or SourceForge, then reinstall it.

answered Mar 26, 2016 at 14:27

Here’s my code:

Sub AttachTemplate()
Dim appWord As Application, TemplateDir As String, Loc As String
Set appWord = GetObject(, «Word.Application»)
TemplateDir = appWord.Options.DefaultFilePath(wdUserTemplatesPath) & «»
Loc = TemplateDir & «poms2012.dotm»

        With ActiveDocument
        .UpdateStylesOnOpen = True
        .AttachedTemplate = Loc
        .XMLSchemaReferences.AutomaticValidation = True
        .XMLSchemaReferences.AllowSaveAsXMLWithoutValidation = False
    End With

End Sub

I removed extraneous stuff so you could see the logic.  It dies at .AttachedTemplate = Loc.  I have tried removing the folllowing two lines, hardcoding the value of Loc, putting in error checking, nothing works.

Background: I have several macros kicking off upon document_open.  There is an embedded template in the document that is first placed in the templates folder.  I have a checker to see if the file is open and waits for it to close (this was removed
for simplicity).  After reassigning the new template, it fixes the styles with another macro and opens the styles window.  These work fine if I remove the macro that attaches the template. 

Please help.  I had it working for a day or so a few months ago.  I came in to work the next day and it failed.  I have no idea what happened.  I need it to work in both 2010 and 2007.  Thank you!


template_c directory not created or not pointing to the right place.

This bug affects 1 person

Affects Status Importance Assigned to Milestone


postfixadmin (Ubuntu)

New

Undecided


Unassigned

Bug Description

When installing postfixadmin from scratch you get an error:

ERROR: the templates_c directory doesn’t exist or isn’t writeable for the webserver

This is because there’s a bug in smarty.inc.php:

        // if it’s not present or writeable, smarty should just not cache.
        $templates_c = dirname(__FILE__) . ‘/../templates_c’;
        if (is_dir($templates_c) && is_writeable($templates_c)) {
  <…>
          die(«ERROR: the templates_c directory doesn’t exist or isn’t writeable for the webserver»);
        }

Where the location of templates_c is (a) hard-coded and (b) hard-coded to a questionable (and relative) location.

The manual fix for this is to create the directory and chown it to www-data:www-data.

Ошибка: Каталог шаблонов не найден

Я клонировал репозиторий git, который кто-то сделал для веб-сайта CodeIgniter. У меня на компьютере настроен сервер WAMP, и он отлично работает. В модулях Apache я включаю rewrite_module и в настройках PHP я включаю short open tag. Я также поместил свои настройки базы данных в applicationconfigdatabase.php файл. После этого я положил папку CodeIgniter в C:wampwwwCodeIgniter папку.

Теперь проблема в том, что когда я иду в localhost/CodeIgniter Я получаю это:

Error: Template Directory Not Found!

Я несколько часов искал эту ошибку в Интернете, но ничего похожего не нашел. Если кто-то видел эту ошибку раньше и знает, как ее решить, я буду очень признателен за любую помощь или за то, что вы можете указать мне правильное направление, так как я новичок в CodeIgniter.

Мне кажется, что ваше приложение использует стороннюю библиотеку шаблонов, а конфигурация неверна.

Найдите в каталоге вашего приложения «Каталог шаблонов не найден» — это приведет вас к тому месту, где в коде находится сообщение об ошибке, и вы сможете выяснить, какая библиотека его вызывает. Или загляните в свое приложение/конфиг — скорее всего для этого есть файл

«Каталог шаблонов не найден» не является частью Codeigniter.

Создан 01 сен.

Не тот ответ, который вы ищете? Просмотрите другие вопросы с метками

php
git
codeigniter
wamp

or задайте свой вопрос.

So far, I’ve been unable to reproduce this issue with dotnet 2.0.0.

One possibility is that your dotnet new configuration, may be in an unexpected state due to previous installs of this template. If you want to reset the template installation to the defaults dotnet new ships with, you can run dotnet new --debug:reinit (this flag is not technically supported, may change / be removed in the future). After running that command, an empty template list will be displayed, but then the next time you run dotnet new, it will go through the first-run code, and setup to be in the initial state. This might be good, to get into a known state before retrying the install / uninstall. But be aware that any other templates you’ve installed will be removed and need to be re-installed.

Another possibility is that we’re subtlely miscommunicating about the paths being used. For my tests, I have a directory structure that looks like:

C:TEMPTEMP_TEMPLATES
---some-template-folder
    |   some-file.txt
    |
    ---.template.config
            template.json

(output from c:temptemp_templates>tree . /A /F)

From the c:temptemp_templates directory, I run the command:
dotnet new --install some-template-folder
… and observe the newly installed template in the template list.

And then to uninistall, I run:
dotnet new --uninstall c:temptemp_templatessome-template-folder
… and observe the template has been removed from the list.

Postgres wants to create a $HOME/.psql_history file, where it will store all your queries and commands from the psql client. It may well want to do something else at $HOME, but I don’t see any evidence in the form of other hidden files. And it won’t actually create the history file unless you’re using psql interactively, which you’re not.

I had this exact same problem and found this question, but the accepted answer wasn’t acceptable to me — I shouldn’t have to grant postgres permission to leave a trail of my queries in whatever directory I happen to be in when I run a script!

@Corey, the solution you mentioned in your comment (cd /tmp before calling sudo...) is probably the best. psql won’t create this file in /tmp (I’m sure that’s deliberate, because it could allow unprivileged users to read the file).

There are two other solutions I can think of :

  1. Run psql in a login shell by adding -i to your command

    sudo -i -u postgres psql < setup_dev_db.sql
    

    This will set $HOME to postgres‘s HOME directory, listed in /etc/passwd. For Ubuntu, that’s /var/lib/postgres. But since you’re piping in commands, it won’t create a .psql_history file. However, if you use interactive psql, anyone else with sudo privileges on the machine will have access to your command history.

    I’m not sure if there are any other negative consequences to running a login shell in this situation.

  2. Run psql as a less-privileged user, e.g.

    $ psql dev_db -hlocalhost corey_dev -W < setup_dev_db.sql
    

    If this is a problem because you leave postgres user creation to your setup_dev_db.sql script, and you don’t have any users yet, just add a createuser command in your script first, something like this:

    $ sudo -u postgres createuser corey_dev -P
    

    and perhaps …

    $ sudo -u postgres createdb dev_db "Dev database"
    

NOTE: When using the psql client interactively (which you’re not, here), if you see a message like could not change directory to "/home/corey/scripts": Permission denied message ****, psql is going to write to /var/lib/postgres/.psql_history (or wherever its $HOME is)! If you’ve ever seen that warning when using interactive psql, go look—you’ll probably find a hidden history file.

0 0 голоса
Рейтинг статьи
Подписаться
Уведомить о
guest

0 комментариев
Старые
Новые Популярные
Межтекстовые Отзывы
Посмотреть все комментарии

А вот еще интересные материалы:

  • Яшка сломя голову остановился исправьте ошибки
  • Ясность цели позволяет целеустремленно добиваться намеченного исправьте ошибки
  • Ясность цели позволяет целеустремленно добиваться намеченного где ошибка
  • Cosmos 2000 smitec 24 ошибка
  • Cos 588 f candy ошибки